0
我正在使用Fishpig Wordpress擴展的Magento網站上工作。我們將「分類」小部件顯示在左側邊欄&中,它被設置爲顯示分層結構。Magento的Fishpig Wordpress擴展分類層次
據工作兩層深(即UL &李與.level0
& .level1
),但沒有顯示類3級深即level2
我一個基本的WordPress安裝測試這我可以讓它顯示3個級別的類別,但我無法通過fishpig WordPress集成在Magento上運行它。我已將帖子分配給所有子類別。
我template/wordpress/sidebar/widget/categories.phtml
看到有這個代碼塊,以獲得1級子類別:
<?php else: ?>
<?php foreach($categories as $category): ?>
<li class="level0 item<?php if ($this->isCurrentCategory($category)): ?> active<?php endif; ?>">
<a class="level0" href="<?php echo $category->getUrl() ?>" title="<?php echo $category->getName() ?>">
<?php echo $category->getName() ?>
</a><?php if ($this->getCount()): ?> (<?php echo $category->getPostCount() ?>)<?php endif; ?>
<?php if ($this->getHierarchical()): ?>
<?php $children = $children = $category->getChildrenCategories() ?>
<?php if (count($children) > 0): ?>
<ul class="level1">
<?php foreach($children as $child): ?>
<?php if ($child->getPostCount() > 0): ?>
<li class="level1 item<?php if ($this->isCurrentCategory($child)): ?> active<?php endif; ?>">
» <a href="<?php echo $child->getUrl() ?>" title="<?php echo $child->getName() ?>" class="level1"><?php echo $child->getName() ?></a><?php if ($this->getCount()): ?> (<?php echo $child->getPostCount() ?>)<?php endif; ?>
</li>
<?php endif; ?>
<?php endforeach; ?>
</ul>
<?php endif; ?>
<?php endif; ?>
</li>
<?php endforeach; ?>
<?php endif; ?>
是否有與Fishpig上的Magento顯示WordPress的類別超過兩級的方法嗎?