Customize Your Magento Account Dashboard: Remove Navigation Links

Posted on: 05 Nov 2019 by Admin

Below are the steps, Magento Developers implements in the customers account dashboard to remove manage navigation links. The links in the customers account dashboard navigation are added via different layout XML files.
NameSpace : Egits

Step 1: Create a php file in app/code/local/Egits/Customer/Block/Account/Navigation.php:

{
 public function removeLinkByName($name)
    {
        unset($this->_links[$name]);
    }  
}

 

Step 2: Rewrite magento account_navigation with Egits_Customer_Block_Account_Navigation a configuration XML file in app\code\local\Egits\Customer\etc\config.xml:

Egits_Customer_Block_Account_Navigation

 

Step 3: Finally you can remove My Account links individually from your local.xml file as :

billing_agreements
recurring_profiles
reviews

This is a list of all names for navigation links in account dashboard (in default order of their appearance):

  1. Account
  2. Account_edit
  3. Address_book
  4. Orders
  5. Billing_agreements
  6. Recurring_profiles
  7. Reviews
  8. Tags
  9. Wishlist
  10. OAuth Customer Tokens
  11. Newsletter
  12. Downloadable products