|   | php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
| 
 PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits              [2004-07-14 06:49 UTC] endrju at itrisinajumi dot lv
  [2004-07-14 11:58 UTC] sesser@php.net
  [2004-07-14 13:05 UTC] alex dot pagnoni at solarix dot it
  [2004-07-14 13:08 UTC] derick@php.net
  [2004-07-15 18:27 UTC] daviidu at everydns dot net
  [2004-07-21 17:00 UTC] tmeader at pobox dot com
  [2004-07-23 03:38 UTC] neilcurry1 at hotmail dot com
  [2004-07-26 03:47 UTC] arthur at petraclc dot com
  [2004-08-10 01:33 UTC] herps at raqtweak dot com
 | |||||||||||||||||||||||||||||||||||||
|  Copyright © 2001-2025 The PHP Group All rights reserved. | Last updated: Sat Oct 25 02:00:01 2025 UTC | 
Description: ------------ When making HTTP authentication there is no $_SERVER["PHP_AUTH_USER"] in headers (but there is $_SERVER["PHP_AUTH_PW"]). I noticed this when i upgraded to PHP 5.0.0 and checked phpMyAdmin - it hanged. After some investigation I found that there's no $_SERVER["PHP_AUTH_USER"] in headers. './configure' '--with-apxs=/usr/local/apache/bin/apxs' '--with-openssl' '--with-imap=../imap-2004/' '--with-mysql=/usr/local/mysql' '--with-mssql' '--with-pgsql' '--with-gd' '--with-png' '--with-zlib' '--with-jpeg' '--with-iconv' '--with-gettext' '--with-xml' '--with-mcrypt' '--enable-mbstring' '--enable-sockets' '--with-bz2' '--enable-calendar' '--enable-bcmath' Reproduce code: --------------- <?php if (!isset($_SERVER['PHP_AUTH_USER'])) { header('WWW-Authenticate: Basic realm="My Realm"'); header('HTTP/1.0 401 Unauthorized'); echo 'Text to send if user hits Cancel button'; exit; } else { echo "<p>Hello {$_SERVER['PHP_AUTH_USER']}.</p>"; echo "<p>You entered {$_SERVER['PHP_AUTH_PW']} as your password.</p>"; } ?> Expected result: ---------------- (This is from http://lv.php.net/manual/en/features.http-auth.php). I Expected that when i enter username, password and press OK, the code will output my entered username and password. Actual result: -------------- Script keeps asking the username and password indefinitely;