0

I want to Override or Change the text of Add to cart Button, With my Admin Panel.

Don't Want to change in back end Code. I find some method that add some xml code in particular page in content section and override the main code. Like:-

referenceBlock name="footer_links" remove="true"/>

referenceBlock name="footer.col.title.1" remove="true"/> "

enter image description here

So is it possible to change in Add to Cart Button text with some HTML code in my admin panel.

1 Answer 1

1

Please first override js file from path

vendor/magento/module-catalog/view/frontend/web/js/catalog-add-to-cart.js

To

app/design/frontend/themename/packagename/Magento_Catalog/web/js/catalog-add-to-cart.js

You have to changes text which you want to from this file.

I hope its work for you.

1
  • Thanks.. i create a simple module. so can i just copy and past this .js file in my module, dose its work. or i have to add more file in my module Commented Jul 12, 2019 at 12:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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