note 15587 deleted from function.eval by jimw
| From: | jimw@php.net | Date: | Sat, 08 Dec 2001 23:26:01 +0000 |
| Subject: | note 15587 deleted from function.eval by jimw | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-22330@lists.php.net to get a copy of this message | ||
You have to buffer the eval output if you want to capture it to save to a file:
<CODE>
// $template is a mixture of html and php variables that need to be eval'ed
$html = join (" ",file ($template));
ob_start();
eval ( "?>" . $html . "<?");
$output = ob_get_contents ();
ob_end_clean();
</CODE>
Now the variable $output can be written to a file!!
Cheers!