#21004 [Opn->Fbk]: Header Location Fails

From: Date: Sun, 15 Dec 2002 22:16:11 +0000
Subject: #21004 [Opn->Fbk]: Header Location Fails
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-27795@lists.php.net to get a copy of this message
ID: 21004 Updated by: sniper@php.net Reported By: tom@minnesota.com -Status: Open +Status: Feedback Bug Type: HTTP related Operating System: NetBSD/Alpha (64bit) - 1.6 PHP Version: 4CVS-2002-12-13 (stable) New Comment: So it works now? Previous Comments: ------------------------------------------------------------------------ [2002-12-15 11:39:03] tom@minnesota.com I tested this on a DSO. There was no error from apache in the log when accessing index.php. ------------------------------------------------------------------------ [2002-12-15 03:51:55] sniper@php.net And how is PHP installed there? DSO or CGI? What does Apache logs have to say about that internal error you're getting? ------------------------------------------------------------------------ [2002-12-14 12:19:42] tom@minnesota.com I don't think it's directing at all. FYI, works fine under PHP-4.2.2, but not CVS. Using 4.3-CVS ------------- # lynx -dump -head http://www.minnesota.com/~tom/php/redir/index.php HTTP/1.1 500 Internal Server Error Date: Sat, 14 Dec 2002 18:13:20 GMT Server: Apache/1.3.27 (Unix) PHP/4.3.0-dev X-Powered-By: PHP/4.3.0-dev Location: http://www.minnesota.com/~tom/php/redir/index2.php Connection: close Content-Type: text/html Using 4.2.2 ----------- # lynx -dump -head http://www.minnesota.com/~tom/php/redir/index.php HTTP/1.1 302 Found Date: Sat, 14 Dec 2002 18:17:29 GMT Server: Apache/1.3.27 (Unix) mod_ssl/2.8.12 OpenSSL/0.9.6g PHP/4.2.2 X-Powered-By: PHP/4.2.2 Location: http://www.minnesota.com/~tom/php/redir/index2.php Connection: close Content-Type: text/html --- In this case I don't think it's Mozilla or IE. ------------------------------------------------------------------------ [2002-12-14 04:11:19] sniper@php.net Does it redirect though? What does 'lynx -dump -head <url to the index.php>' output? Maybe IE6 and Mozilla 1.2b are more strict about the path? Since your example adds one extra / in the url.. ------------------------------------------------------------------------ [2002-12-13 19:12:45] tom@minnesota.com RE: Bug #19754 shouldn't be closed because CVS-2002-12-13 still exihibit this problem. index.php: <?php $location = "Location: http://".$_SERVER['HTTP_HOST']; $location.= dirname($_SERVER['PHP_SELF'])."/"."index2.php"; header($location); ?> --- index2.php: <?php echo "<p>You have been redirected</p>"; ?> --- calling index.php should redir to index2.php and echo out: You have been redirected Instead both Mozzila 1.2b and IE 6.x show a blank page. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=21004&edit=1

« previous php.bugs (#27795) next »