PDA

View Full Version : PHP and $DOCUMENT_ROOT


Jeff_Gross
04-07-2001, 01:15 AM
I am new to php and am trying to move my website over from another server. I think my problem relates to the fact that I have switched the DNS registration from my old site to HostRocket, but I am not sure.

I am trying to include files in my web pages and the $DOCUMENT_ROOT variable is not resolving to what I think it should. It has a value of
/home/abiza/public_html

but I think it should resolve to
/home/jeffgros/public_html

what do I have to do to change this?

I found a reference at http://www.php.net/manual/en/security.php
in Case 3. The third paragraph states

"You can set the PHP script document root by the configuration directive doc_root in the configuration file, or you can set the environment variable PHP_DOCUMENT_ROOT. If it is set, the CGI version of PHP will always construct the file name to open with this doc_root and the path information in the request, so you can be sure no script is executed outside this directory"

Jeff_Gross
04-12-2001, 10:30 PM
Tech support fixed this problem. I do not know what they did.