I need to change the text on an item in a 3rd party extension from "Apply" to "Redeem". Since Apply is used in other modules as well I want to make sure to only affect instance of "apply" in the module specifically.

In Magento 1 this could be done using the line below in the theme's translation file...


I tried this in Magento 2 and it does not seem to work and I didn't see any mention of an alternative in the Magento Translate Docs. Is there a way to accomplish this in Magento 2?


You can use "Apply", "Redeem", module, Module_Name

Example in devdocs

"Add to Cart", "Add to Cart", module, Magento_Review

"Add to Cart", "Add to Shopping Cart", module, Magento_Catalog

| improve this answer | |

This can be done by creating an independent language translation file inside your 3rd party extension (custom module).

First create i18n directory inside your custom module
Then create a language file and name it en_US.csv
Inside that language file put your translation

Apply, Redeem

Save it then run cache:flush

It should translate only the specific 'apply' from your custom module and will not affect any other module using the 'apply' instance

check if it works!

| improve this answer | |
  • I am having the same issue. While this method works, since the extension is 3rd party, translations get deleted whenever the extension is updated. – P. Kouvarakis Aug 13 '19 at 12:35

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.