Edit Customer links
How do I edit the customer menu links?
For example, hide the 'Download menu or Saved Credit Card menu, etc
Most of the articles I have read use the following instructions but does not seem to work with the Pearl Theme
https://inchoo.net/magento-2/managing-my-account-navigation-links-magento-2/
-
Official comment
Pearl uses the same customization process as a default Magento. As such, if the instructions in the article you linked work on a default Magento, they should also work fine with Pearl.
Make sure you're extending the correct Magento files in the Child Theme. Let's take a quick example, such as removing the My Downloadable Products link from the Account Page. I would extend the customer_account.xml in the following path: app/design/frontend/Pearl/weltpixel_custom/Magento_Customer/layout
Then, adding the following code to that should do the trick:
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="customer-account-navigation-downloadable-products-link" remove="true"/>
</body>
</page>This principle applies to other links as well, and you can find a list of all the defined blocks in Magento here: https://gist.github.com/joshfortyfour/86839915e4f5cac0904c00007ca1d356
Assure that you also flush all your available Caches in the Magento Backend (and external caches if you have any), and then check the frontend. Also, check out this article we have that goes over customizations more in-depth, with a few examples: https://support.weltpixel.com/hc/en-us/articles/115000705293-How-to-customize-css-xml-phtml-js-files-in-Magento-2-examples-Tutorial-
Comment actions
Please sign in to leave a comment.
Comments
2 comments