Posted by John K on 10/09/38 11:36
In ASP/IIS if I want to point to a folder/directory in the root as an
in include I write this...
<!--#include virtual="/menu.asp" -->
In PHP/Apache I have to do this...
<?php include "menu.php" ?> or something like this....
My problem is in asp I can reference this file from any
folder/directory. For example, if I were here.... "/admin/default.asp"
I could reference the include as is. In php I can't do this, at least
I don't know how to. Another problem is that if there are file paths
in the include itself this problem comes up again. I know I could
write this <?php include "../menu.php"?> and it would find it's way to
the file but what about the file paths in the include? This is a menu
with relative paths to images.
How can I point at a file in the root from any directory in my website
using a relative path? I know I should probably avoid an http://
reference.
Thanks!!
[Back to original message]
|