I'm trying to setup php includes to add in a header file throughout an entire website, but I'm having a problem with it.
domain.com/index.php works fine using an include of the following format:
<?php include("./ssi/include.htm") ?>
But, the same include code will not work from pages in directories other than the root directory of the site. For example, domain.com/directory/index.php will not include the file in the above code.
Using the default includes directory setting in php.ini isn't an option for me.
I need to be able to include the files in a way relative to the root of the website & not using the actual system path.
I can do this without any problem using regular server side includes, but cannot seem to figure out how to do it using php includes.
Thanks in advance for any help.