Reputation: 55
The thing is that I have logo displayed on only homepage in Magento checking if it's homepage with getIsHomepage();. Now the thing I want to do is to display logo inside header only on Dashboard page, do you know any alternative to getIsHomepage but to check if it's My account page?
Thanks
Upvotes: 0
Views: 494
Reputation: 8050
It's best practice to use xml to do this instead of parsing url. Add this to your local.xml:
<customer_account_index>
<reference name="header">
<action method="setTemplate"><template>page/html/customer_account_header.phtml</template></action>
</reference>
</customer_account_index>
And copy and edit your header.phtml file to template/page/html/customer_account_header.phtml
Upvotes: 1
Reputation: 7611
If you want to out logic for customer account page then
First fetch current routers and controllers and action to headere.phtml
logic is like for magento customer dasboard page url is customer/account/index
then
<?php $action = Mage::app()->getFrontController()->getAction();
echo $action->getFullActionName('_');
if($action->getFullActionName('_')=="customer_account_index")
{
}
?>
Upvotes: 0