Storing templates in SQL
| From: | Eaden McKee | Date: | Sun, 09 Mar 2003 08:43:31 +0000 |
| Subject: | Storing templates in SQL | ||
| Groups: | php.smarty.general | ||
| Request: | Send a blank email to php-smarty-general+get-8493@lists.php.net to get a copy of this message | ||
Hi there,
I would like to store templates in mysql. Or, more to the point, would like to be able to do something like $smarty->display($actual_template_code) i.e, be able to pass the actual template code to some smarty function and get it to compile and display it.
The reason for wanting this, is user updatable templates, but on a large scale system, and file system saves is not desirable. I also wonder about timestamps and possably I can store these in mysql too.
I would be grateful for any pointers on what fuctions I should look into. Looking at the code there is a lot of filesystem specific stuff, I hope what I want is reasonably achievable.
Thanks in advance,
Eaden McKee