You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Fernando Reuter Wendt <fe...@admijui.unijui.tche.br> on 2002/04/26 13:29:36 UTC

PHP vs. Apache Enviroment Variables

Hello,

now, i was hopping that installing one Perl interpreter would solve the
problem i have with the Apache Environment Variables (SERVER_NAME,
SERVER_PORT ...), that aren´t working. I´m trying to get them at one PHP
file (like 'echo "Server Name:" . $SERVER_NAME'). In my local workstation,
running Win2K, Apache 1.3.24 and PHP 4.2.0 it doesn´t output the values, but
at our webserver, running Linux, Apache 1.3.23 and PHP 4.0.6 it works. Some
one knows about this?

Thank you,

+---------------------
 Fernando A. R. Wendt

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: PHP vs. Apache Enviroment Variables

Posted by Neil Freeman <ne...@asa.co.uk>.
PHP v4.2.0 has global variables turned off by default. You will need to use
alternative arrays for accessing the information. See the change log for more
info.

Fernando Reuter Wendt wrote:

> *************************************************************************
> This Message Was Virus Checked With : SAVI 3.54 Feb 2002
> Last Updated 24th April 2002
> *************************************************************************
>
> Hello,
>
> now, i was hopping that installing one Perl interpreter would solve the
> problem i have with the Apache Environment Variables (SERVER_NAME,
> SERVER_PORT ...), that aren´t working. I´m trying to get them at one PHP
> file (like 'echo "Server Name:" . $SERVER_NAME'). In my local workstation,
> running Win2K, Apache 1.3.24 and PHP 4.2.0 it doesn´t output the values, but
> at our webserver, running Linux, Apache 1.3.23 and PHP 4.0.6 it works. Some
> one knows about this?
>
> Thank you,
>
> +---------------------
>  Fernando A. R. Wendt
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org

--
--------------------------------
 Email:  neil.freeman@asa.co.uk
         neil@curvedvision.com
--------------------------------



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org