I need to change the categories page title if their 'Page Title' attribute did not specify. It should set to their 'Name' attribute.
If I switch back to default theme the page title is correct so I think there's something in my custom layout xml files. I added a block with customer/form_login
type in my head
section and there's this line of code inside its class:
File: app/code/core/Mage/Customer/Block/Form/Login.php:
protected function _prepareLayout()
{
$this->getLayout()->getBlock('head')
->setTitle(Mage::helper('customer')
->__('Customer Login')); // <-- This sets the title
return parent::_prepareLayout();
}
I heard everywhere on the net to comment out this line but I don't want to do this because of two reasons:
- It is bad and ugly even if I copy the whole file into
app/code/local
folder. - I noticed that the default theme will set the title correctly even if I include the login form block inside its
head
. So it must be something inside my layout files.
Any idea would be appreciated.