note 23662 added to function.header

From: Date: Wed, 24 Jul 2002 12:41:50 +0000
Subject: note 23662 added to function.header
Groups: php.notes 
Request: Send a blank email to php-notes+get-33499@lists.php.net to get a copy of this message
This doesn't work for me: <?php header("HTTP/1.0 404 Not Found"); ?> Or: <?php header("HTTP/1.0 401 Unauthorized"); ?> As well I did switch HTTP/1.0 for HTTP/1.1. The only thing I keep getting at my Apache server, is a blank screen in IE 6.0. I tried with PHP 4.2.1 and 4.2.2 on Apache 2.0.39 and Apache 1.3.22 (both Apache's with .htaccess file containing ErrorDocuments for 401 and 404). I mean if I do something like http://rohs.nl/dsfsdfd then I get my customized 404, from .htaccess. But as soon as I use the header() from PHP nothing but a blank screen appears. So what's this header() function about? The only thing I can do with it is "Location:" and "WWW-authenticate:" But "HTTP/" doesn't work. -- http://www.php.net/manual/en/function.header.php http://master.php.net/manage/user-notes.php?action=edit+23662 http://master.php.net/manage/user-notes.php?action=delete+23662 http://master.php.net/manage/user-notes.php?action=reject+23662

« previous php.notes (#33499) next »