Making php execute php
| From: | Gord Gray | Date: | Wed, 18 Jul 2001 14:32:16 +0000 |
| Subject: | Making php execute php | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-58444@lists.php.net to get a copy of this message | ||
I would like to store a mix of php and html in a database and then return
the results. I can't figure out how to do this.
$abc='<div class="bob"><?php echo "$Message" ;
?></div>' ;
...
$Message="Hello World" ;
...
echo eval ($abc) ;
where $abc is actually retrieved from a database.
Does not work, but may illustrate what I am trying to accompish. If anyone
has any hints on how I can do this, I would be very grateful.
Thanks,
Gord.