Exemplo n.º 1
0
 /**
  * function to update compiled template file in templates_c folder
  * Prior to PHP5.3.0, when refering to the class with a variable, like $icmsAdminTpl, you
  * still need to use the arrow operator instead of ::
  * http://www.php.net/manual/en/language.oop5.paamayim-nekudotayim.php
  *
  * The proper way to use this would be
  * icms_view_Tpl::template_touch($tplid);
  * or
  * $icmsAdminTpl->template_touch($tplid);
  *
  * @param   string  $tpl_id
  * @return  boolean
  **/
 public static function template_touch($tpl_id)
 {
     $tplfile_handler =& icms::handler('icms_view_template_file');
     $tplfile =& $tplfile_handler->get($tpl_id);
     if (is_object($tplfile)) {
         $file = $tplfile->getVar('tpl_file', 'n');
         $tpl = new icms_view_Tpl();
         return $tpl->touch("db:{$file}");
     }
     return false;
 }