0
我想獲取類別圖像到當前的兒童類別列表,我用下面的代碼檢索。當前類別圖像的兒童類別
我該怎麼做?
<?php
$i=0;
$count=1;
echo '<div class="empty-row">';
$_categories = $this->getCurrentChildCategories();
foreach($_categories as $_category):
{
if($i %3 ==0)
{ ?>
</div>
<div class="row">
<div class="item <?php if($count > 6) echo 'nobg'; ?>">
<h2><a href="<?php echo $_category->getURL() ?>" title="<?php echo $this->htmlEscape($_category->getName()) ?>"><?php echo $this->htmlEscape($_category->getName()) ?> »</a></h2>
</div>
<? }
else
{ ?>
<div class="item <?php if($count > 6) echo 'nobg'; ?>">
<h2><a href="<?php echo $_category->getURL() ?>" title="<?php echo $this->htmlEscape($_category->getName()) ?>"><?php echo $this->htmlEscape($_category->getName()) ?> »</a></h2>
</div>
<? }
$i++;
}
$count++; endforeach;
?>
非常感謝! – Michael 2012-03-07 08:35:40