I8n Error / Hin Text in Controller
-
Hello,
in existing php controller like:
/.hotelcommerce/controllers/front/OrderOpcController.php
still English Error Notes and Hints.
if (!$this->context->cookie->checkedTOS && Configuration::get('PS_CONDITIONS')) { return '<p class="warning">'.Tools::displayError('**Please accept the Terms of Service.**').'</p>'; }
How can I replace this with I8n ? Using TPL like
{l s='THE NEW ERROR'}
does not work.
-
Hi @michi,
To translate this text in the controller you don't need to make any changes to the code. You can translate the error messages in QloApps with the following steps:
- Go to "Translations" in the "Localization" tab.
Select the type of translation as "Error message translations" then select the language and click on modify.
- After this you will be able to update the translations for the error messages for the front controller.
- Go to "Translations" in the "Localization" tab.