2

Simple question, how to translate string "settings" on mobile menu?

enter image description here

1
  • Have you added a translated string in csv file? Jun 14, 2019 at 5:41

1 Answer 1

1

Add below code in your csv file (I have add translated text for italian)

"Settings","impostazioni"

Copy file from below path

vendor/magento/module-theme/view/frontend/templates/html/sections.phtml

And past into your theme directory.

app/design/frontend/Themefolder/themename/Magento_Theme/templates/html/sections.phtml

And change code from <?= /* @escapeNotVerified */ $label ?> To <?php /* @escapeNotVerified */ echo __($label); ?>

If you want to translate string in .html file then you have to use <?php echo __('your string'); ?>

Fore more refrance check this

I hope it helps!

2
  • Worked just this --> "Settings","impostazioni" thank you
    – Silver
    Jun 14, 2019 at 7:04
  • You are welcome :) Jun 14, 2019 at 8:19

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.