tags:

views:

41

answers:

1

Hello,

I have a portion of page in footer.phtml whose content I want to change on each new page, according to different categories. How can I get this done, or can I access product attribute outside of the product page? Is this possible?

regards

+2  A: 

You can do this by defining your own block, though the specifics depend on more detail about the requirement. Define a block that will output the footer content you want whenever you are on a page with the current category defined:

$category = Mage::registry("current_category");
if($category) {
    // write your output here
}

$product = Mage::registry("current_product");
if($product) {
    // write your output here
}

Note that it is generally bad practice to have your global footer change based on each page. At that point, it isn't a global footer any longer.

Thanks, Joe

Joseph Mastey
thanks for the reply sir,well plz have a look at this link http://www.testwsi.com/magento/ the pages contains three different Headline section in the footer,which I want to change on Each Category Page In other words wanna show 3 other Category descriptions
Okay, edit your question to add what you've tried in the footer, preferably taking into account the above ways of getting the current category and product.
Joseph Mastey