Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
- Virtual servers and $_SERVER[DOCUMENT_ROOT]
- George Zervakos
June 23, 2006, 5:51 pm
rate this thread
I'm new to php and was wondering if someone could help me out with the best
way to accomplish this.
I have Solaris 9/Apache 1.3.31/PHP 5.1.4 that I compiled from source code
I have multiple virtual web servers configured in httpd.conf and php scripts
run only if they are placed in my first VirtualHost DocumentRoot directory
as defined in httpd.conf:
I would like to get php scripts to run in one of my other virtual servers
defined in httpd.conf.
Right now, my $_SERVER[DOCUMENT_ROOT] gets defined (I think) from httpd.conf
such that it points to /usr/local/apache/sites/webdocdir. This I can see
from the results of a phpinfo().
Is there some way of configuring Apache and/or php so that I am not forced
to put php scripts in /usr/local/apache/sites/webdocdir?
thanks for any help,
Re: Virtual servers and $_SERVER[DOCUMENT_ROOT]
You might try alt.apache.configuration for some help.
It does work; I have my Apache set up with multiple virtual hosts and PHP works
fine in any directory in each host.
I don't know what you've got incorrect in your Apache configuration, but it's
Remove the "x" from my email address
JDS Computer Training Corp.
- » How do I make & a literal character in an XML parse?
- — Previous thread in » PHP Scripting Forum