cancel
Showing results for 
Search instead for 
Did you mean: 

$_SERVER['PHP_AUTH_USER'] not working

xpher
Grafter
Posts: 58
Registered: 02-08-2007

$_SERVER['PHP_AUTH_USER'] not working

Hi
Trying to use
<?php echo $_SERVER['PHP_AUTH_USER'] ?>


to get username from htaccess login but it returns nothing. Same with $_SERVER['REMOTE_USER'] not working.
Any ideas
1 REPLY
prichardson
Grafter
Posts: 1,503
Registered: 05-04-2007

Re: $_SERVER['PHP_AUTH_USER'] not working

Our CCGi service uses PHP as a CGI wrapper and is not installed as a module.
As per the PHP documentation, this specific feature is not available in this configuration.
http://uk.php.net/manual/en/features.http-auth.php
There are some minor workarounds which are available in the above link for CGI mode, however these are not available on CGI either, unless you do some other mod_rewrite work to make your site work.