I want to change english validation messages in overall app.
so for example:
showing "field required" rather than "date of birth is required".
I tried to configure the I18N component as following:
'i18n' => [
'translations' => [
'*' => [
'class' => 'yii\i18n\PhpMessageSource',
'basePath' => '@common/messages',
'sourceLanguage' => 'en',
'fileMap' => [
'yii' => 'yii.php',
]
// 'on missingTranslation' => ['app\components\TranslationEventHandler', 'handleMissingTranslation']
],
],
but not working