php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #11759 DOCUMENT_ROOT not available when using PHP with IIS5 (cgi Version)
Submitted: 2001-06-27 19:37 UTC Modified: 2001-06-28 12:16 UTC
From: blankart at muenchen-lottoteam dot de Assigned:
Status: Not a bug Package: IIS related
PHP Version: 4.0.6 OS: W2K
Private report: No CVE-ID: None
 [2001-06-27 19:37 UTC] blankart at muenchen-lottoteam dot de
DOCUMENT_ROOT not available when using PHP with IIS5 (cgi Version). Works fine on Linux / Apache


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-06-27 19:41 UTC] blankart at muenchen-lottoteam dot de
<? echo $DOCUMENT_ROOT; ?> </P>

Causes the following:

Warning: Undefined variable: DOCUMENT_ROOT in w:\inetpub\wwwroot\test1.php4 on line 13




 [2001-06-28 12:16 UTC] brianlmoon@php.net
DOCUMENT_ROOT is an environment/server variable set by Apache.  You will need to determine the equivalent if there is one for IIS.

Brian.
 [2004-01-14 14:32 UTC] m dot v dot d dot wetering at xs4all dot nl
To solve this problem set the DOCUMENT_ROOT variable in the environment on your server (ControlPanel >> System >> Advanced >> Environment variables...). I set the variable in the System variables part and after a reboot the variable is accessible through PHP.

(Tested on Windows2000 with IIS 5)
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Nov 22 20:01:31 2024 UTC