|
Posted by Ben Allen on 05/28/06 19:13
Hi,
I have a form where a user can enter different feild, for simplicities sake,
say a 'To:', 'From' and 'Message' feild. The can select a 'template' from
the databse, each one has different layouts, images etc, and is sotred as
HTML code in the mySql. My question is how do I insert the vairables into
the correct places in the template? I realise if it was hard-coded I could
use something like:
echo "To:". $to. "<br><br>". $message. "<br><br>From:". $from;
etc, although this is simplified alot and the ones int databse contain
images, tables, css etc. I don't really want to hardcode them using IF
statements as I want it to be easy to add new 'templates'.
Thanks
Ben
Navigation:
[Reply to this message]
|