Re: Apache2/PHP: Undefined server variables
| From: | Richard Lynch | Date: | Sun, 23 Sep 2001 20:18:13 +0000 |
| Subject: | Re: Apache2/PHP: Undefined server variables | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-68449@lists.php.net to get a copy of this message | ||
Check httpd.conf to see what, if anything, is in there that might be set to
alter Apache's server variables.
If phpinfo() aren't showing them, it's probably Apache isn't sending them.
--
WARNING richard@zend.com address is an endangered species -- Use
ceo@l-i-e.com
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
----- Original Message -----
From: Art Boulatov <art@ksu.ru>
Newsgroups: php.general
To: <php-general@lists.php.net>
Sent: Sunday, September 23, 2001 9:27 AM
Subject: Apache2/PHP: Undefined server variables
> Hi,
>
> sorry if this is a dumb question (I think I've read the docs :)
>
> I 've just set up Apache-2.0.26-dev with php-4.0.8-dev both from CVS,
> and now when I try to access the server variables like:
>
> <?php echo $SERVER_NAME ?> or <?php echo $HTTP_USER_AGENT ?>
>
> I got "Undefined variable:" in the logs.
>
> The same is for:
>
> <?php echo $HTTP_SERVER_VARS[SERVER_NAME] ?>
>
> I played with php.ini with no effect.
>
> Could you please tell me if this happens due to misconfiguration of
> php/apache, or thats a known issue with Apache-2.0 and php?
>
> Also, under phpinfo() I cannot see any server variables at all, only those
> from the shell environment.
>
> Thanks a lot,
> Art.