本文整理匯總了PHP中Area::getTotalBlocksInArea方法的典型用法代碼示例。如果您正苦於以下問題:PHP Area::getTotalBlocksInArea方法的具體用法?PHP Area::getTotalBlocksInArea怎麽用?PHP Area::getTotalBlocksInArea使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Area
的用法示例。
在下文中一共展示了Area::getTotalBlocksInArea方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: Area
$disable_page_info = true;
}
if ($pageid != 1 && $disable_page_info == 1) {
$this->inc('elements/page-meta.php');
}
?>
<?php
$a = new Area('Header Image');
$blocks = $a->getTotalBlocksInArea($c);
if ($blocks > 0 || $c->isEditMode()) {
echo '<div class="c5h-banner-wrap clearfix">';
echo ' <div class="row">';
echo ' <div class="small-12 columns">';
$a->display($c);
echo ' </div>';
echo ' </div><!-- END .row -->';
echo '</div><!-- END .c5h-banner-wrap -->';
}
?>
<?php
$a = new Area('Header Image Full');
$blocks = $a->getTotalBlocksInArea($c);
if ($blocks > 0 || $c->isEditMode()) {
echo '<div class="c5h-banner-wrap-full clearfix">';
$a->display($c);
echo '</div><!-- END .c5h-banner-wrap-full -->';
}
?>
</header>
示例2: Area
?>
<div class="spacer"></div>
<?php
if ($c->isEditMode()) {
?>
</div>
<?php
}
?>
<div id="header-area">
<div class="divider"></div>
<div id="header-area-inside">
<?php
$ah = new Area('Header');
$ah->display($c);
?>
</div>
<?php
if ($ah->getTotalBlocksInArea() > 0) {
?>
<div class="divider"></div>
<?php
}
?>
</div>
</div>
示例3: die
<?php
defined('C5_EXECUTE') or die("Access Denied.");
$this->inc('elements/header.php');
$pageHeader = new Area('Page Header');
$pageHeader->enableGridContainer();
$pageHeaderBlocks = $pageHeader->getTotalBlocksInArea($c);
$displayPageHeader = $pageHeaderBlocks > 0 || $c->isEditMode();
$pageContent = new Area('Page Content');
$pageContent->enableGridContainer();
$pageContentBlocks = $pageContent->getTotalBlocksInArea($c);
$displayPageContent = $pageContentBlocks > 0 || $c->isEditMode();
$pageFooter = new Area('Page Footer');
$pageFooter->enableGridContainer();
$pageFooterBlocks = $pageFooter->getTotalBlocksInArea($c);
$displayPageFooter = $pageFooterBlocks > 0 || $c->isEditMode();
?>
<main>
<section class="ui page header">
<?php
$pageHeader->display($c);
?>
</section>
<?php
if ($displayPageContent) {
?>
<section class="ui page content container">
<?php
$pageContent->display($c);