1

The site that I am working on is using he_IL as primary language of the theme (I think). I installed a plugin which only has en_US.csv its i18 folder

I added an he_IL.csv in the i18l folder, but I don't see that it is picked up in the UI.

I tried running these commands, and refresh the UI (ctrl-f5) but it is still not working.

php bin/magento setup:di:compile 
php bin/magento setup:static-content:deploy -f en_US he_IL --language en_US --language he_IL 
php bin/magento cache:clean; php bin/magento cache:flush

I checked, and the string that I want to replace is wrapped in __() inside the phtml file.

What am I missing?

1

1 Answer 1

2

Create some new translations with:

php bin/magento i18n:collect-phrases -o     app/code/Company/Module/i18n/he_IL.csv app/code/Company/Module

This will create the csv file that you want, in the place it has to be and with the translation strings that you need.

If your __() is not in there then you will need to look at your code.

2
  • I don't know why, but the plugin i18l files didn't work. I ended up changing the text from the template i18l language file, it did work from there.
    – justadev
    Dec 16, 2020 at 16:27
  • 1
    On a further check, I don't know what happened, but after running your command and changing the texts in the generated file, suddenly it worked. So I am accepting your answer. Thanks!
    – justadev
    Dec 16, 2020 at 16:41

Your Answer

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

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