本文整理汇总了PHP中TemplateEngine::clearVariable方法的典型用法代码示例。如果您正苦于以下问题:PHP TemplateEngine::clearVariable方法的具体用法?PHP TemplateEngine::clearVariable怎么用?PHP TemplateEngine::clearVariable使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TemplateEngine
的用法示例。
在下文中一共展示了TemplateEngine::clearVariable方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: handleNewGet
/**
* handle new
*/
private function handleNewGet()
{
$template = new TemplateEngine($this->getPath() . "templates/" . $this->templateFile);
$request = Request::getInstance();
$view = ViewManager::getInstance();
$view->setType(self::VIEW_NEW);
$fields = $this->getFields(SqlParser::MOD_INSERT);
$template->setVariable($fields);
$template->clearVariable('ip');
$this->director->theme->handleAdminLinks($template);
$this->template[$this->director->theme->getConfig()->main_tag] = $template;
}
示例2: handleNewGet
/**
* handle new
*/
private function handleNewGet()
{
$template = new TemplateEngine($this->getPath() . "templates/" . $this->templateFile);
$request = Request::getInstance();
$view = ViewManager::getInstance();
$view->setType(NewsLetter::VIEW_GROUP_NEW);
$tree_id = intval($request->getValue('tree_id'));
$tag = $request->getValue('tag');
$key = array('tree_id' => $tree_id, 'tag' => $tag);
$fields = $this->getFields(SqlParser::MOD_INSERT);
$fields['tree_id'] = $tree_id;
$fields['tag'] = $tag;
$template->setVariable($fields);
$template->clearVariable('id');
// add breadcrumb item
$this->handleBreadcrumb($template);
$this->template[$this->director->theme->getConfig()->main_tag] = $template;
}
示例3: handleNewGet
/**
* handle new
*/
private function handleNewGet()
{
$template = new TemplateEngine($this->getPath() . "templates/" . $this->templateFile);
$request = Request::getInstance();
$view = ViewManager::getInstance();
$view->setType(NewsLetter::VIEW_USER_NEW);
$tree_id = intval($request->getValue('tree_id'));
$tag = $request->getValue('tag');
$key = array('tree_id' => $tree_id, 'tag' => $tag);
$fields = $this->getFields(SqlParser::MOD_INSERT);
$fields['tree_id'] = $tree_id;
$fields['tag'] = $tag;
$template->setVariable($fields);
$template->clearVariable('id');
$template->setVariable('cbo_gender', Utils::getHtmlCombo($this->getGenderTypeList(), $fields['gender']));
// add breadcrumb item
$grp_used = $request->getValue('grp_used');
$this->handleEdit($template, $grp_used);
$this->template[$this->director->theme->getConfig()->main_tag] = $template;
}