My book says to put this [php]$DOCUMENT_ROOT = $_SERVER[‘DOCUMENT_ROOT’];[/php] into the script, so that I can later use $DOCUMENT_ROOT to open a file. But when I do this, I get an “undefined index” message. What did I do wrong?
The server may not be configured properly or give you another error. Can you post back with the output of:
[php]print_r($_SERVER);[/php]
Whoops! The error was not caused by the line the line I posted. So problem solved! For now anyway. Thanks for responding.