Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Función isHome() o similar (como la de WordPress)
 
kcmr-z
Jr. Member
 
Total Posts:  3
Joined:  2009-06-01
 

Hola.
¿Alguien sabe si Magento tiene una función que permita saber si la página actual es la home? Algo como el isHome() de WordPress.

Gracias.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Damian Culotta
Enthusiast
 
Total Posts:  878
Joined:  2008-12-10
Argentina
 

Probá con algo como esto:

<?php
$page 
Mage::app()->getFrontController()->getRequest()->getRouteName();
 
if (
$page == 'cms'):
    echo 
Mage::getSingleton('cms/page')->getTitle();
endif;
?>
 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top