本文整理匯總了PHP中BlockPlugin::getBlockContext方法的典型用法代碼示例。如果您正苦於以下問題:PHP BlockPlugin::getBlockContext方法的具體用法?PHP BlockPlugin::getBlockContext怎麽用?PHP BlockPlugin::getBlockContext使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類BlockPlugin
的用法示例。
在下文中一共展示了BlockPlugin::getBlockContext方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: getBlockContext
/**
* Get the block context. Overrides parent so that the plugin will be
* displayed during install.
* @return int
*/
function getBlockContext()
{
if (!Config::getVar('general', 'installed')) {
return BLOCK_CONTEXT_RIGHT_SIDEBAR;
}
return parent::getBlockContext();
}
示例2: getBlockContext
/**
* Get the block context. Overrides parent so that the plugin will be
* displayed during install.
* @return int
*/
function getBlockContext()
{
if (!Config::getVar('general', 'installed')) {
return BLOCK_CONTEXT_HOMEPAGE;
}
return parent::getBlockContext();
}
示例3: getBlockContext
/**
* @see BlockPlugin::getBlockContext()
*/
function getBlockContext()
{
$blockContext = parent::getBlockContext();
// Place the block on the left by default
// where navigation will usually be expected
// by the user.
if (!in_array($blockContext, $this->getSupportedContexts())) {
$blockContext = BLOCK_CONTEXT_LEFT_SIDEBAR;
}
return $blockContext;
}
示例4: getBlockContext
/**
* @see BlockPlugin::getBlockContext()
*/
function getBlockContext()
{
$blockContext = parent::getBlockContext();
// Place the block on the right by default.
if (!in_array($blockContext, $this->getSupportedContexts())) {
$blockContext = BLOCK_CONTEXT_SIDEBAR;
}
return $blockContext;
}