Re: PHP Authentication

From: Date: Thu, 21 Feb 2002 17:43:22 +0000
Subject: Re: PHP Authentication
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-12204@lists.php.net to get a copy of this message
HTTP Auth does not work with the CGI version of PHP which is what I presume you are using on Windows. Switch back to UNIX. On 21 Feb 2002 jmt2que001@sneakemail.com wrote: > We just switched servers from Unix to Windows NT and all our authentication stopped working. It > brings up an internal server error. We installed the newest PHP and the newest Apache software. > Pretty much everything else works, except the authentication won't work. I've tried many > different versions of the code. Here is the last version that I tried. Any ideas on what might be > causing this > server error? > > <?php > if (!isset($PHP_AUTH_USER)){ > header( 'WWW-Authenticate: Basic realm="Private"' ); > header( 'HTTP/1.0 401 Unauthorized' ); > echo 'Authorization Required.'; > exit; > } else { > echo 'Success!'; > } > ?> > > > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.windows (#12204) next »