/** * 模板渲染 * * @param string $template 模板文件 * @return htmlcode */ public function fetch($template = '') { $hashkey = core_debug::info('compile template: ' . $template); $html = $this->getRender()->fetch($template); core_debug::upTime($hashkey); return $html; }
public function display($params = array()) { $loadWidgetHashkey = core_debug::info('load widget: ' . get_class($this)); $params = $this->params($params); $compileWidgetHashkey = core_debug::info('compile widget: ' . $this->tpl()); $this->render->display($this->tpl()); core_debug::upTime($loadWidgetHashkey); core_debug::upTime($compileWidgetHashkey); }