How to remove items count from Compare products link in header The 2019 Stack Overflow Developer Survey Results Are In Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Remove header part and add new header from my custom module magento 2.0.1?Magento 2 remove My Account and Wishlist link from top linksHow can I move compare product link in header | Magento 2Magento2 - How to remove “or” from header.linksRemoving wishlist link - top header magento 2Magento 2 remove reference container block from layoutHow to remove minicart from sticky headerMagento 2.1.8- How to disable or remove images from all products in the frontend?How to add header link in magento 2.1How to remove a specific href from a top-menu link in Magento 2

Is every episode of "Where are my Pants?" identical?

Am I ethically obligated to go into work on an off day if the reason is sudden?

How to delete random line from file using Unix command?

Is above average number of years spent on PhD considered a red flag in future academia or industry positions?

Did the new image of black hole confirm the general theory of relativity?

What is this lever in Argentinian toilets?

Why is superheterodyning better than direct conversion?

How did passengers keep warm on sail ships?

Mortgage adviser recommends a longer term than necessary combined with overpayments

Why did all the guest students take carriages to the Yule Ball?

How does ice melt when immersed in water

Is there a writing software that you can sort scenes like slides in PowerPoint?

Can a novice safely splice in wire to lengthen 5V charging cable?

Are spiders unable to hurt humans, especially very small spiders?

Is it ethical to upload a automatically generated paper to a non peer-reviewed site as part of a larger research?

Create an outline of font

Wall plug outlet change

What was the last x86 CPU that did not have the x87 floating-point unit built in?

Why not take a picture of a closer black hole?

Typeface like Times New Roman but with "tied" percent sign

Problems with Ubuntu mount /tmp

Segmentation fault output is suppressed when piping stdin into a function. Why?

First use of “packing” as in carrying a gun

Can undead you have reanimated wait inside a portable hole?



How to remove items count from Compare products link in header



The 2019 Stack Overflow Developer Survey Results Are In
Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Remove header part and add new header from my custom module magento 2.0.1?Magento 2 remove My Account and Wishlist link from top linksHow can I move compare product link in header | Magento 2Magento2 - How to remove “or” from header.linksRemoving wishlist link - top header magento 2Magento 2 remove reference container block from layoutHow to remove minicart from sticky headerMagento 2.1.8- How to disable or remove images from all products in the frontend?How to add header link in magento 2.1How to remove a specific href from a top-menu link in Magento 2



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








0















I don't want to remove the whole link from frontend theme I just want to remove a part of the link.
I don't know where the file that I should edit it
any help?










share|improve this question




























    0















    I don't want to remove the whole link from frontend theme I just want to remove a part of the link.
    I don't know where the file that I should edit it
    any help?










    share|improve this question
























      0












      0








      0








      I don't want to remove the whole link from frontend theme I just want to remove a part of the link.
      I don't know where the file that I should edit it
      any help?










      share|improve this question














      I don't want to remove the whole link from frontend theme I just want to remove a part of the link.
      I don't know where the file that I should edit it
      any help?







      magento2 frontend toplinks






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked 2 days ago









      nashwa ghazynashwa ghazy

      1




      1




















          1 Answer
          1






          active

          oldest

          votes


















          0














          The PHTML file for header compare product is
          MAGENTO-ROOT/vendor/magento/module-catalog/view/frontend/templates/product/compare/link.phtml



          you can copy the PHTML file to your them and comment out the line as below



          Original code:



          <?php
          /**
          * Copyright © Magento, Inc. All rights reserved.
          * See COPYING.txt for license details.
          */

          // @codingStandardsIgnoreFile
          ?>
          <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
          <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
          data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
          >
          <?= /* @escapeNotVerified */ __('Compare Products') ?>
          <span class="counter qty" data-bind="text: compareProducts().countCaption"></span>
          </a>
          </li>
          <script type="text/x-magento-init">
          "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
          </script>


          Change the phtml code it to



          <?php
          /**
          * Copyright © Magento, Inc. All rights reserved.
          * See COPYING.txt for license details.
          */

          // @codingStandardsIgnoreFile
          ?>
          <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
          <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
          data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
          >
          <?= /* @escapeNotVerified */ __('Compare Products') ?>
          <!--<span class="counter qty" data-bind="text: compareProducts().countCaption"></span>-->
          </a>
          </li>
          <script type="text/x-magento-init">
          "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
          </script>





          share|improve this answer























            Your Answer








            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "479"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: false,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f269787%2fhow-to-remove-items-count-from-compare-products-link-in-header%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            The PHTML file for header compare product is
            MAGENTO-ROOT/vendor/magento/module-catalog/view/frontend/templates/product/compare/link.phtml



            you can copy the PHTML file to your them and comment out the line as below



            Original code:



            <?php
            /**
            * Copyright © Magento, Inc. All rights reserved.
            * See COPYING.txt for license details.
            */

            // @codingStandardsIgnoreFile
            ?>
            <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
            <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
            data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
            >
            <?= /* @escapeNotVerified */ __('Compare Products') ?>
            <span class="counter qty" data-bind="text: compareProducts().countCaption"></span>
            </a>
            </li>
            <script type="text/x-magento-init">
            "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
            </script>


            Change the phtml code it to



            <?php
            /**
            * Copyright © Magento, Inc. All rights reserved.
            * See COPYING.txt for license details.
            */

            // @codingStandardsIgnoreFile
            ?>
            <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
            <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
            data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
            >
            <?= /* @escapeNotVerified */ __('Compare Products') ?>
            <!--<span class="counter qty" data-bind="text: compareProducts().countCaption"></span>-->
            </a>
            </li>
            <script type="text/x-magento-init">
            "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
            </script>





            share|improve this answer



























              0














              The PHTML file for header compare product is
              MAGENTO-ROOT/vendor/magento/module-catalog/view/frontend/templates/product/compare/link.phtml



              you can copy the PHTML file to your them and comment out the line as below



              Original code:



              <?php
              /**
              * Copyright © Magento, Inc. All rights reserved.
              * See COPYING.txt for license details.
              */

              // @codingStandardsIgnoreFile
              ?>
              <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
              <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
              data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
              >
              <?= /* @escapeNotVerified */ __('Compare Products') ?>
              <span class="counter qty" data-bind="text: compareProducts().countCaption"></span>
              </a>
              </li>
              <script type="text/x-magento-init">
              "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
              </script>


              Change the phtml code it to



              <?php
              /**
              * Copyright © Magento, Inc. All rights reserved.
              * See COPYING.txt for license details.
              */

              // @codingStandardsIgnoreFile
              ?>
              <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
              <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
              data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
              >
              <?= /* @escapeNotVerified */ __('Compare Products') ?>
              <!--<span class="counter qty" data-bind="text: compareProducts().countCaption"></span>-->
              </a>
              </li>
              <script type="text/x-magento-init">
              "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
              </script>





              share|improve this answer

























                0












                0








                0







                The PHTML file for header compare product is
                MAGENTO-ROOT/vendor/magento/module-catalog/view/frontend/templates/product/compare/link.phtml



                you can copy the PHTML file to your them and comment out the line as below



                Original code:



                <?php
                /**
                * Copyright © Magento, Inc. All rights reserved.
                * See COPYING.txt for license details.
                */

                // @codingStandardsIgnoreFile
                ?>
                <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
                <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
                data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
                >
                <?= /* @escapeNotVerified */ __('Compare Products') ?>
                <span class="counter qty" data-bind="text: compareProducts().countCaption"></span>
                </a>
                </li>
                <script type="text/x-magento-init">
                "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
                </script>


                Change the phtml code it to



                <?php
                /**
                * Copyright © Magento, Inc. All rights reserved.
                * See COPYING.txt for license details.
                */

                // @codingStandardsIgnoreFile
                ?>
                <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
                <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
                data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
                >
                <?= /* @escapeNotVerified */ __('Compare Products') ?>
                <!--<span class="counter qty" data-bind="text: compareProducts().countCaption"></span>-->
                </a>
                </li>
                <script type="text/x-magento-init">
                "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
                </script>





                share|improve this answer













                The PHTML file for header compare product is
                MAGENTO-ROOT/vendor/magento/module-catalog/view/frontend/templates/product/compare/link.phtml



                you can copy the PHTML file to your them and comment out the line as below



                Original code:



                <?php
                /**
                * Copyright © Magento, Inc. All rights reserved.
                * See COPYING.txt for license details.
                */

                // @codingStandardsIgnoreFile
                ?>
                <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
                <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
                data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
                >
                <?= /* @escapeNotVerified */ __('Compare Products') ?>
                <span class="counter qty" data-bind="text: compareProducts().countCaption"></span>
                </a>
                </li>
                <script type="text/x-magento-init">
                "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
                </script>


                Change the phtml code it to



                <?php
                /**
                * Copyright © Magento, Inc. All rights reserved.
                * See COPYING.txt for license details.
                */

                // @codingStandardsIgnoreFile
                ?>
                <li class="item link compare" data-bind="scope: 'compareProducts'" data-role="compare-products-link">
                <a class="action compare no-display" title="<?= /* @escapeNotVerified */ __('Compare Products') ?>"
                data-bind="attr: 'href': compareProducts().listUrl, css: 'no-display': !compareProducts().count"
                >
                <?= /* @escapeNotVerified */ __('Compare Products') ?>
                <!--<span class="counter qty" data-bind="text: compareProducts().countCaption"></span>-->
                </a>
                </li>
                <script type="text/x-magento-init">
                "[data-role=compare-products-link]": "Magento_Ui/js/core/app": <?= /* @escapeNotVerified */ $block->getJsLayout() ?>
                </script>






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered yesterday









                Pritam Info 24Pritam Info 24

                79217




                79217



























                    draft saved

                    draft discarded
















































                    Thanks for contributing an answer to Magento Stack Exchange!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid


                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.

                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f269787%2fhow-to-remove-items-count-from-compare-products-link-in-header%23new-answer', 'question_page');

                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Get product attribute by attribute group code in magento 2get product attribute by product attribute group in magento 2Magento 2 Log Bundle Product Data in List Page?How to get all product attribute of a attribute group of Default attribute set?Magento 2.1 Create a filter in the product grid by new attributeMagento 2 : Get Product Attribute values By GroupMagento 2 How to get all existing values for one attributeMagento 2 get custom attribute of a single product inside a pluginMagento 2.3 How to get all the Multi Source Inventory (MSI) locations collection in custom module?Magento2: how to develop rest API to get new productsGet product attribute by attribute group code ( [attribute_group_code] ) in magento 2

                    Category:9 (number) SubcategoriesMedia in category "9 (number)"Navigation menuUpload mediaGND ID: 4485639-8Library of Congress authority ID: sh85091979ReasonatorScholiaStatistics

                    Magento 2.3: How do i solve this, Not registered handle, on custom form?How can i rewrite TierPrice Block in Magento2magento 2 captcha not rendering if I override layout xmlmain.CRITICAL: Plugin class doesn't existMagento 2 : Problem while adding custom button order view page?Magento 2.2.5: Overriding Admin Controller sales/orderMagento 2.2.5: Add, Update and Delete existing products Custom OptionsMagento 2.3 : File Upload issue in UI Component FormMagento2 Not registered handleHow to configured Form Builder Js in my custom magento 2.3.0 module?Magento 2.3. How to create image upload field in an admin form