1

How to remove Stored payment method links from the navigation menu on customer account page?

  • could u share us screenshot please? – Nagaraju Kasa Jul 13 '17 at 13:27
1

You can remove by add this code to your theme default.xml file.

<referenceBlock name="customer-account-navigation-my-credit-cards-link" remove="true"/>
4

You can remove all links using the code below, just add a file:

app/design/frontend/[Namespace]/[Theme]/Magento_Customer/layout/customer_account.xml

<?xml version="1.0"?>
<!--
/**
 * Copyright © 2016 Magento. All rights reserved.
 * See COPYING.txt for license details.
 */
-->
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <!-- Remove unwanted account navigation links -->
        <!-- Put this file in: app/design/frontend/[Namespace]/[Theme]/Magento_Customer/layout/customer_account.xml -->

        <!-- Store credit -->
        <referenceBlock name="customer-account-navigation-customer-balance-link" remove="true"/>

        <!-- Downloadable product link -->
        <referenceBlock name="customer-account-navigation-downloadable-products-link" remove="true"/>

        <!-- Subscription link -->
        <referenceBlock name="customer-account-navigation-newsletter-subscriptions-link" remove="true"/>

        <!-- Billing agreement link -->
        <referenceBlock name="customer-account-navigation-billing-agreements-link" remove="true"/>

        <!-- Product review link -->
        <referenceBlock name="customer-account-navigation-product-reviews-link" remove="true"/>

        <!-- My credit card link -->
        <referenceBlock name="customer-account-navigation-my-credit-cards-link" remove="true"/>

        <!-- Account link -->
        <referenceBlock name="customer-account-navigation-account-link" remove="true"/>

        <!-- Account edit link -->
        <referenceBlock name="customer-account-navigation-account-edit-link" remove="true"/>

        <!-- Address link -->
        <referenceBlock name="customer-account-navigation-address-link" remove="true"/>

        <!-- Orders link -->
        <referenceBlock name="customer-account-navigation-orders-link" remove="true"/>

        <!-- Wish list link -->
        <referenceBlock name="customer-account-navigation-wish-list-link" remove="true"/>

        <!-- Gift card link -->
        <referenceBlock name="customer-account-navigation-gift-card-link" remove="true"/>

        <!-- Order by SKU -->
        <referenceBlock name="customer-account-navigation-checkout-sku-link" remove="true"/>

        <!-- Gift registry -->
        <referenceBlock name="customer-account-navigation-giftregistry-link" remove="true"/>

        <!-- Reward points -->
        <referenceBlock name="customer-account-navigation-reward-link" remove="true"/>

        <!-- Invitation -->
        <referenceBlock name="customer-account-navigation-magento-invitation-link" remove="true"/>
    </body>
</page>
1

Go to your layout file from your custom module for example:

Here i am giving you sample example:

go to layout file

Layout handle content:

<?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-wish-list-link" remove="true"/>
        <referenceBlock name="customer-account-navigation-billing-agreements-link" remove="true"/>
    </body>
</page>
  • only remove store payment method – Devidas Jul 13 '17 at 13:32
  • just i am giving u sample example – Nagaraju Kasa Jul 13 '17 at 13:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.