note 62869 added to function.ob-start
| From: | ironoxid at libero dot it | Date: | Sat, 11 Mar 2006 13:37:25 +0000 |
| Subject: | note 62869 added to function.ob-start | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-105269@lists.php.net to get a copy of this message | ||
Look at this
<?php
class PAGE {
public function __construct(){
ob_start(NULL,NULL,false);
print_r(ob_get_status());
}
public function __destruct(){
print_r(ob_get_status());
}
}
$P = NEW PAGE;
?>
The first print_r print
Array
(
[level] => 2
[type] => 1
[status] => 0
[name] => default output handler
[del] =>
)
But the second print
Array ( )
So, don't expect to use ob_get_contents() or similar in classes destructors.
----
Server IP: 213.92.11.19
Probable Submitter: 151.56.41.213
----
X-Spam-Status: No, hits=3.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER
autolearn=no version=2.64
----
Manual Page -- http://www.php.net/manual/en/function.ob-start.php
Edit -- http://master.php.net/note/edit/62869
Del: integrated -- http://master.php.net/note/delete/62869/integrated
Del: useless -- http://master.php.net/note/delete/62869/useless
Del: bad code -- http://master.php.net/note/delete/62869/bad+code
Del: spam -- http://master.php.net/note/delete/62869/spam
Del: non-english -- http://master.php.net/note/delete/62869/non-english
Del: in docs -- http://master.php.net/note/delete/62869/in+docs
Del: other reasons-- http://master.php.net/note/delete/62869
Reject -- http://master.php.net/note/reject/62869
Search -- http://master.php.net/manage/user-notes.php