Hi
Is it possible to include a php file from a different folder to a php file?
ie. I like to include /phpfiles/php.file to file.php in my root folder.
Hi
Is it possible to include a php file from a different folder to a php file?
ie. I like to include /phpfiles/php.file to file.php in my root folder.
Sure…
Unix / Linux
<?php include("PathToFolder/FileToInclude.txt"); ?>
relative to your web root (this would assume a folder named PathToFolder directly under your web root)
Hi
Thanks for youre quick reply.
I cant get it working. Im trying to include the wxpic-V1-02.php script from Jordan.
See this:
You may have to use the full path…
/home/whatever/etc/etc/file.txt
or even
As I use IIS and PHP there always seems to be a problem with certain scripts as there was with this particular one. On Jordans advice I now just use this code
img src="wspic-V1-02.php"
and it works well. Don’t know if this is your issue but maybe it will help!
Hi again
Thanks for your replies.
Im sorry but I cant get it working.
See this file: http://www.buskelundtoften.dk/1/test.php - where i have tried du include the file wspic.php located here:
http://www.buskelundtoften.dk/1/vejret/hjemmeside/vejrudsigt/wspic.php
I think its just not formated properly
try this
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>Ny side 1</title>
</head>
<body>
<img src="http://www.buskelundtoften.dk/1/vejret/hjemmeside/vejrudsigt/wspic.php "alt="forecast">
</body>
</html>
Hi Steve
Its working now - thank you very much for your help.
Have a nice day
Your welcome
the site looks good!
Steve