note 63294 added to function.ob-start

From: Date: Sat, 18 Mar 2006 18:34:05 +0000
Subject: note 63294 added to function.ob-start
Groups: php.notes 
Request: Send a blank email to php-notes+get-106044@lists.php.net to get a copy of this message
if you want output buffering to not work worth a damn, try the following: obtest2.php: -------------- <?php include("obtest.php"); a_start("foo"); echo "foo"; ?> bar! <?php Header("Location: ./index.php"); a_end(); ?> obtest.php: ------------ <?php $foo='bar'; function a_start($val){ ob_start(""); $foo="bar"; echo "foo, bar, foo, bar<br />"; ?> foo, bar, foo, bar<br /> foo, <?php echo $foo.", ".$val; ?>, bar<br /> <? echo "foo, bar, foo, bar<br />"; } function a_end(){ ?> foobar! <?php ob_end_flush(); } ?> index.php: ------------ <?php echo "you'll never get here unless you have output_buffering set to On in your php config file perhaps!"; ?> ---- Server IP: 66.207.199.35 Probable Submitter: 198.53.253.173 ---- X-Spam-Status: No, hits=4.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER, HTML_30_40,HTML_MESSAGE autolearn=no version=2.64 ---- Manual Page -- http://www.php.net/manual/en/function.ob-start.php Edit -- http://master.php.net/note/edit/63294 Del: integrated -- http://master.php.net/note/delete/63294/integrated Del: useless -- http://master.php.net/note/delete/63294/useless Del: bad code -- http://master.php.net/note/delete/63294/bad+code Del: spam -- http://master.php.net/note/delete/63294/spam Del: non-english -- http://master.php.net/note/delete/63294/non-english Del: in docs -- http://master.php.net/note/delete/63294/in+docs Del: other reasons-- http://master.php.net/note/delete/63294 Reject -- http://master.php.net/note/reject/63294 Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#106044) next »