note 39800 added to function.ob-start
| From: | webmaster at pzfn dot com | Date: | Wed, 11 Feb 2004 03:19:54 +0000 |
| Subject: | note 39800 added to function.ob-start | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-64988@lists.php.net to get a copy of this message | ||
If for some reason you want to store an include in a variable you might have noticed that the
followinf doesn work...
<?
$var = include("file");
?>
A work around for this is...
<?
ob_start();
include("file");
$var = ob_get_contents();
ob_end_clean();
?>
I hope that helps somebosy... it sure would have helped me...
----
Manual Page -- http://www.php.net/manual/en/function.ob-start.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+39800
Delete -- http://master.php.net/manage/user-notes.php?action=delete+39800&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+39800&report=yes
Search -- http://master.php.net/manage/user-notes.php