Magento – Want to get meta_title ( Page Title in category )

categorymagento-1.9meta

I want to add to get page title in title tag (of head )
i tried

<?php if ($_category->getMetaTitle()):?>
    <?php echo $_helper->categoryAttribute($_category, $_category->getMetaTitle(), 'meta_title') ?>
<?php else: ?

enter image description here

enter image description here

Best Answer

simply add this in your head

if(Mage::registry('current_category'))
{
   echo  Mage::registry('current_category')->getMetaTitle();
}else {

 echo $this->getTitle()
 }
Related Topic