note 109833 modified in function.ob-get-clean by danbrown
| From: | danbrown@php.net | Date: | Fri, 31 Aug 2012 15:41:11 +0000 |
| Subject: | note 109833 modified in function.ob-get-clean by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-190317@lists.php.net to get a copy of this message | ||
<?php ob_start(); echo
"1"; $content =
ob_get_clean(); echo
"2"; $content .=
ob_get_clean(); echo
$content; ?> This script outputs 21 in
CLI mode and 12 otherwise (under my apache and nginx)
--was--
<?php
ob_start();
echo "1";
$content = ob_get_clean();
echo "2";
$content .= ob_get_clean();
echo $content;
?>
This script outputs 21 in CGI mode and 12 otherwise (under my apache and nginx)
http://php.net/manual/en/function.ob-get-clean.php