本文整理匯總了PHP中PwSeoBo::getData方法的典型用法代碼示例。如果您正苦於以下問題:PHP PwSeoBo::getData方法的具體用法?PHP PwSeoBo::getData怎麽用?PHP PwSeoBo::getData使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類PwSeoBo
的用法示例。
在下文中一共展示了PwSeoBo::getData方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: postHandle
public function postHandle()
{
//門戶管理模式 編譯目錄切換
if ($this->getRequest()->getPost('design')) {
$loginUser = Wekit::getLoginUser();
$designPermission = $loginUser->getPermission('design_allow_manage.push');
if ($designPermission > 0) {
$dir = Wind::getRealDir('DATA:design.template');
if (is_dir($dir)) {
WindFolder::rm($dir, true);
}
$this->forward->getWindView()->compileDir = 'DATA:design.template';
}
}
// SEO settings
Wind::import('SRV:seo.bo.PwSeoBo');
$sitename = Wekit::C('site', 'info.name');
PwSeoBo::set('{sitename}', $sitename);
Wekit::setGlobal(NEXT_VERSION . ' ' . NEXT_RELEASE, 'version');
Wekit::setGlobal(PwSeoBo::getData(), 'seo');
$this->setOutput($this->getRequest()->getIsAjaxRequest() ? '1' : '0', '_ajax_');
/*[設置給PwGlobalFilters需要的變量]*/
$_var = array('current' => $this->forward->getWindView()->templateName, 'a' => $this->router->getAction(), 'c' => $this->router->getController(), 'm' => $this->router->getModule());
$this->getResponse()->setData($_var, '_aCloud_');
Wekit::load('APPS:appcenter.service.srv.PwDebugApplication')->compile();
}
示例2: run
/**
* 錯誤提示
*
* @see WindErrorHandler::run()
*/
public function run()
{
$this->setOutput($this->state, 'state');
if (isset($this->error['data'])) {
$this->setOutput($this->error['data'], 'data');
unset($this->error['data']);
}
$this->setOutput($this->error, "message");
$this->setTemplate('TPL:common.error');
// set layout for common request
if (!$this->getRequest()->getIsAjaxRequest()) {
$this->setLayout('TPL:common.layout_error');
Wind::import('SRV:seo.bo.PwSeoBo');
$lang = Wind::getComponent('i18n');
PwSeoBo::setCustomSeo($lang->getMessage('SEO:' . $this->state . '.page.title'), '', '');
PwSeoBo::set('{sitename}', Wekit::C('site', 'info.name'));
Wekit::setGlobal(NEXT_VERSION, 'version');
Wekit::setGlobal(PwSeoBo::getData(), 'seo');
}
}