note 84380 added to function.header

From: Date: Fri, 11 Jul 2008 01:35:11 +0000
Subject: note 84380 added to function.header
Groups: php.notes 
Request: Send a blank email to php-notes+get-141393@lists.php.net to get a copy of this message
Note that if you don't want to go through the process of making sure that there is no output before you send a header, you can use <?php ob_start(); ?> at the beginning of your page. This starts the output buffer, which allows you to send headers whenever you feel like it. Make sure that you put it at the BEGINNING, after the first php tag. It allows you to do something like <?php ob_start(); echo 'foo'; header("Status: 404 Not Found"); echo 'bar'; ?> ---- Server IP: 209.41.74.194 Probable Submitter: 74.215.203.72 ---- Manual Page -- http://www.php.net/manual/en/function.header.php Edit -- https://master.php.net/note/edit/84380 Del: integrated -- https://master.php.net/note/delete/84380/integrated Del: useless -- https://master.php.net/note/delete/84380/useless Del: bad code -- https://master.php.net/note/delete/84380/bad+code Del: spam -- https://master.php.net/note/delete/84380/spam Del: non-english -- https://master.php.net/note/delete/84380/non-english Del: in docs -- https://master.php.net/note/delete/84380/in+docs Del: other reasons-- https://master.php.net/note/delete/84380 Reject -- https://master.php.net/note/reject/84380 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#141393) next »