note 15389 rejected and deleted from features.http-auth by zak
| From: | zak@php.net | Date: | Fri, 07 Sep 2001 19:00:03 +0000 |
| Subject: | note 15389 rejected and deleted from features.http-auth by zak | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-17785@lists.php.net to get a copy of this message | ||
Help. I'm using the following code to do authentication with Apache:
if(!isset($PHP_AUTH_USER))
{
Header("WWW-Authenticate: Basic realm="Quinielas"");
Header("HTTP/1.0 401 Unauthorized");
Header("Location: error.php");
exit;
}
else
{
echo "Hello $PHP_AUTH_USER.";
echo "You entered $PHP_AUTH_PW as your password.";
}
Everytime I use this code I got the following response (if $PHP_AUTH_USER) is not init:
---------------------------
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your
request.
Please contact the server administrator, lffranco@pemex.com and inform them of the time the error
occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
---------------------------
Looks like a missconfiguration on Apache, but really I dunno. Can anybody help?