Question

I saw on RELEASE_NOTES.txt on CE 1.8:

  • Fixed #17451: Header Links (top.links.phtml) does not output correctly because it is using the model code (the Toplinks block is deprecated)

However, the $this->getChildHtml('topLinks') call on the demo frontend template seems to output links which addLink method of Mage_Page_Block_Html_Toplinks created: shopping cart, login etc.

I didn't understand that. What is the supposed way of adding those links ?

Thanks.

Was it helpful?

Solution

Mage_Page_Block_Html_Toplinks is indeed deprecated since 1.4.0.1. The new block for adding links is now Mage_Page_Block_Template_Links, which also holds a addLink method. If you check the page.xml you will notice the new block within the header block: <block type="page/template_links" name="top.links" as="topLinks"/>.

So the functionality stays the same, although this new block is more a generic solution instead of just for the header top links.

Licensed under: CC-BY-SA with attribution
Not affiliated with magento.stackexchange
scroll top