Magento – Remove Specific Top Links

magento-1.9toplinksxml

I need to edit the Magento Top Links in a specific way and only need to show three links in below order

Login  Register  Cart

This would result in following

  1. Remove only Checkout Link and not Cart Link
  2. Remove My account Link and add Register Link instead
  3. Rename My Cart to Cart

How can I achieve this ?

Please Guide.

Thanks !!!

Best Answer

You can also remove some of the top links in your local.xml by referencing them and removing them by name.

<reference name="top.links">
   <remove name="wishlist_link"/>
   <remove name="checkout_cart_link"/>
</reference>

This only work if the top link was created with a name like this:

<reference name="top.links">
   <block type="wishlist/links" name="wishlist_link" />
   <action method="addLinkBlock"><blockName>wishlist_link</blockName></action>
</reference>

For the log in and log out, since they aren't called with a "name", you can't remove it this way.