jcadima
8/22/2016 - 8:14 PM

Magento get current category name and ID

Magento get current category name and ID


<?php

$catId = Mage::getModel('catalog/layer')->getCurrentCategory()->getId(); 
$catName = Mage::getModel('catalog/layer')->getCurrentCategory()->getName();