Hi,
I need some way to extract data from a MySQL database in such a way that it works the same way as include() or require(). My problem is this: the way I have my database set up now, there is a table for code and a table for HTML. The HTML table has a variable in it, like %variable%. The main file that uses the database eval()'s the code from the code table and then str_replace()'s it into the HTML. This works somewhat well, but it's not very efficient when I am trying to write code.
Does anyone know a way that I can put code, enclosed in the standard <?PHP and ?> tags, combined with HTML into a database and have it parse the code and not try to parse the HTML? Eval() will try to parse the HTML and return the expected error. I am not even sure if there is a way to do this, but any information on it would be greatly appreciated.