MySQL Resource
Resource Implementation based on the Custom API to use MySQL as the storage resource for Smarty's templates and configs.
Table definition:
CREATE TABLE IF NOT EXISTS `templates` ( `name` varchar(100) NOT NULL, `modified` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, `source` text, PRIMARY KEY (`name`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
Demo data:
INSERT INTO `templates` (`name`, `modified`, `source`) VALUES ('test.tpl', "2010-12-25 22:00:00", '{$x="hello world"}{$x}');
Located in /demo/plugins/resource.mysql.php (line 23)
Smarty_Resource | --Smarty_Resource_Custom | --Smarty_Resource_Mysql
Inherited from Smarty_Resource
Smarty_Resource::$compileds
Smarty_Resource::$compiler_class
Smarty_Resource::$resources
Smarty_Resource::$sources
Smarty_Resource::$sysplugins
Smarty_Resource::$template_lexer_class
Smarty_Resource::$template_parser_class
Fetch a template and its modification time from database
Fetch a template's modification time from database
Inherited From Smarty_Resource_Custom
Smarty_Resource_Custom::fetch()
Smarty_Resource_Custom::fetchTimestamp()
Smarty_Resource_Custom::getBasename()
Smarty_Resource_Custom::getContent()
Smarty_Resource_Custom::populate()
Inherited From Smarty_Resource
Smarty_Resource::buildFilepath()
Smarty_Resource::config()
Smarty_Resource::fileExists()
Smarty_Resource::getBasename()
Smarty_Resource::getContent()
Smarty_Resource::load()
Smarty_Resource::populate()
Smarty_Resource::populateCompiledFilepath()
Smarty_Resource::populateTimestamp()
Smarty_Resource::source()
Documentation generated on Sat, 24 Sep 2011 20:23:17 +0200 by phpDocumentor 1.4.1