I am using the following block in my Magento CMS for home site:
{{block type="catalog/product_list" name="catalog_list" category_id="1420" template="catalog/product/listStart.phtml"}}
How can I just get an output of all subcategories of the category_id as specified in the block (id 1420 in this case).
So far I have the following code:
<?php
$_category = $this->getCurrentCategory();
$collection = Mage::getModel('catalog/category')->getCategories($_category->entity_id);
$helper = Mage::helper('catalog/category');
?>
<div class="category-products">
<div id="carousel">
<ul class="products-in-row">
<?php $i=0; foreach ($collection as $cat): ?>
<li class="item">
<?php echo $cat->getName();?>
</li>
<?php endforeach ?>
</ul>
</div>
I'm getting all subcategories of the main category only.