public static function init($option = array()) { $options = array_merge(self::$larOptions, $option); $smarty = new Smarty(); $smarty->force_compile = $options['force']; $smarty->debugging = $options['debug']; $smarty->caching = $options['caching']; $smarty->cache_lifetime = $options['cache']; $smarty->template_dir = FPATH_TEMPLATES; $smarty->compile_dir = FPATH_COMPILES; $smarty->config_dir = FPATH_CONFIGS; $smarty->cache_dir = FPATH_CACHE; self::$obSmarty = $smarty; }
public static function init($option = array()) { $options = array_merge(self::$larOptions, $option); $smarty = new Smarty(); $smarty->force_compile = $options['force']; $smarty->debugging = $options['debug']; $smarty->caching = $options['caching']; $smarty->cache_lifetime = $options['cache']; $smarty->template_dir = "templates"; $smarty->compile_dir = "compiles"; $smarty->config_dir = "configs"; $smarty->cache_dir = "cache"; self::$obSmarty = $smarty; }