IIS: $_SERVER & referer
Emmanuel. M. Decarie
emm at scriptdigital.com
Mon May 12 16:19:46 EDT 2003
PHP Version 4.2.2
Windows NT 5.0
Hello,
I'm working for a client that have the configuration above.
It seems that the $_SERVER global is not created and so I can't use
for example $_SERVER['PHP_SELF ']. No big deal since I can get the
same info with getenv('SCRIPT_NAME').
I can ask the client to make modifications to the server php.ini and
I was wondering if there is something to do there.
I had a look here, but don't see any answers.
<http://www.php.net/manual/en/reserved.variables.php#reserved.variables.server>
Also, I'd like to find a way to get the referer. $_ENV is not
available (variables_order doesn't contains 'E' in php.ini) but I
doubt its a solution since I did some test with Perl listing all the
environment variable and there is no referer variable that I can see.
I tried that in Perl:
#! perl -w
use CGI ':standard';
print header ('text/plain');
foreach $k (keys %ENV) {
print "$k = $ENV{$k}\
";
}
and this (with CGI.pm): referer ().
without results.
The CGI Environment Variables defined on the following page doesn't
seems to list a way to get the referer so I don't see how I could use
getenv for that.
<http://hoohoo.ncsa.uiuc.edu/cgi/env.html>
TIA
Cheers
-Emmanuel
--
______________________________________________________________________
Emmanuel Décarie / Programmation pour le Web - Programming for the Web
Radio UserLand/Frontier - Perl - PHP - Javascript <http://scriptdigital.com/>
Blog: <http://blog.scriptdigital.com> - AIM: scriptdigital
More information about the talk
mailing list