Get Current Category Id in Magento

Use the below code to get the current category id category ID in magento

 echo Mage::getModel('catalog/layer')->getCurrentCategory()->getId(); 

Cheers!
Amjath

Leave a Reply

Your email address will not be published. Required fields are marked *