I have developed some PHP software that can be used by many different sites. Some of the functions and standard variables used by this software are stored in include files which I would like stored outside of the webserver root directory. Obviously this is a matter of setting up the include_path to point outside of the root directory. No problem so far.
If I then have two sites using this software that are based on the same virtual server they will share the include_path which is where my problem occurs. One of the include()ed files is a file setting up site specific variables so obviously cannot be the same for both sites. I want this file to have a standard name as the sofware is effectively a package and I do not want to have to create individually tailored PHP files for each site.
So my question is this. Is there any way I can overcome this problem. I don't want to use individually tailored PHP code in any way. I thought of doing something like working out the site name from an environment variable in PHP (if that is possible) and then looking for the include files in a directory of that name, but I can't seem to get the include_path to work with subdirectories. Is this correct?
Any ideas would be appreciated,
Thanks in advance,
Chrber