Re: buffering headers before send

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"M. Sokolewicz" <tularis@xxxxxxx> schrieb im Newsbeitrag
> ob_start buffers both `normal` output AND headers.

Humm, now it works...
Is there something else that must be set, so that ob_start() works or not?
Something like an php.ini entry?

Here is the listing of ob_start.php5

<?php
ob_start();
echo "hallo first<BR>";
$x = ob_get_clean();
ob_start();
header("X-Sample-Test: foo");
$h[0] = headers_sent();
$h[1] = headers_list();
echo "hallo second<BR>";
echo $x;
$x = ob_get_clean();
ob_start();
echo "hallo third<BR>";
echo $x;
header("X-Sample-Test: foo2");
$h[2] = headers_sent();
$h[3] = headers_list();
ob_end_flush();
echo "<PRE>";
var_dump($h);
echo "</PRE>";
?> 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux