I've got the following design:
the hierarchical structure of my website is stored inside of a MySQL database. The database itself contains the various menu entries and for each menu items also the parent of this item and the content of the page, currently HTML. This all works fine, but now I would also like to embed PHP code as content. I can easily print HTML code, but what about PHP? Is there a way to "execute" (!!) the PHP code embedded in the string I retrieve from the database? (some kind of meta design).
Another way would be to parse the embedded code myself, inventing my own language: example: stored in the database for menu entry "home":
<h1>Welcome</h1>
<lookup USERS *>
where tag lookup retrieves some important stuff from table USERS....which I would have to replace while parsing the content...
any hints how to avoid this redirection I mentioned first? recommendations?
Thanks in advance