Authored by tmq

添加品牌广告位

... ... @@ -7,7 +7,7 @@ class Controller_Brand extends Controller_Abstract
public function indexAction()
{
$banners = Facade_Index::getIndex(1);
$banners = Facade_Index::getIndex(3);
$this->_view['partnerList'] = Facade_Partner::getPartner();
$this->_view['partnerTypes'] = Facade_Partner::$types;
$this->_view['banners'] = $banners;
... ...
... ... @@ -81,11 +81,9 @@
</li>
EOL;
$groupLen ++;
if ($groupLen >= 8) {}
if($groupLen>= 16)
{
$templates[] ='<div class="{class}"><h2>'.$type.'</h2><hr><ul class="clearfix">'.$html.'</ul></div>';
$templates[] ='<div class="box big-size clearfix"><h2>'.$type.'</h2><hr><ul class="clearfix">'.$html.'</ul></div>';
$html = '';
$groupLen = 0;
$groupNum = 0;
... ... @@ -93,13 +91,13 @@ EOL;
}
if(!empty($html))
{
$templates[] ='<div class="{class}"><h2>'.$type.'</h2><hr><ul class="clearfix">'.$html.'</ul></div>';
$templates[] ='<div class="box big-size clearfix"><h2>'.$type.'</h2><hr><ul class="clearfix">'.$html.'</ul></div>';
$html = '';
}
$groupNum ++;
if($groupNum == 2 && !empty($html))
{
$templates[] ='<div class="{class}"><h2>'.$type.'</h2><hr><ul class="clearfix">'.$html.'</ul></div>';
$templates[] ='<div class="box clearfix"><h2>'.$type.'</h2><hr><ul class="clearfix">'.$html.'</ul></div>';
$html = '';
$groupNum = 0;
$groupLen = 0;
... ... @@ -116,7 +114,7 @@ EOL;
else
{
$temp = preg_replace('@<div class="(.*)">(.+)<\/div>@isU', "\\2", $temp);
$template .='<div class="box big-size clearfix">'.$temp.'</div>';
$template .='<div class="box clearfix">'.$temp.'</div>';
}
}
... ...