 CakePHP Cookbook Documentation 5.xtranslation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); directory of your application. Next, create the translations file under resources/locales/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Cake\I18n\MessagesFileLoader as Loader; I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 1080 页 | 939.39 KB | 1 年前3 CakePHP Cookbook Documentation 5.xtranslation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); directory of your application. Next, create the translations file under resources/locales/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Cake\I18n\MessagesFileLoader as Loader; I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 1080 页 | 939.39 KB | 1 年前3
 CakePHP Cookbook Documentation 5.xtranslation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); } } The directory of your application. Next, create the translations file under resources/locales/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Cake\I18n\MessagesFileLoader as Loader; I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 848 页 | 2.53 MB | 1 年前3 CakePHP Cookbook Documentation 5.xtranslation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); } } The directory of your application. Next, create the translations file under resources/locales/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Cake\I18n\MessagesFileLoader as Loader; I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 848 页 | 2.53 MB | 1 年前3
 CakePHP Cookbook 3.x
translation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); src/I18n/Parser directory of your application. Next, create the translations file under src/Locale/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Prior to 3.5 use translator() I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 1244 页 | 1.05 MB | 1 年前3 CakePHP Cookbook 3.x
translation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); src/I18n/Parser directory of your application. Next, create the translations file under src/Locale/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Prior to 3.5 use translator() I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 1244 页 | 1.05 MB | 1 年前3
 CakePHP Cookbook 3.x
translation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); } } The src/I18n/Parser directory of your application. Next, create the translations file under src/Locale/fr_FR/animals.yaml 738 Chapter 21. Internationalization & Localization CakePHP Cookbook Documentation, Release 3.10 // Prior to 3.5 use translator() I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 967 页 | 2.80 MB | 1 年前3 CakePHP Cookbook 3.x
translation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); } } The src/I18n/Parser directory of your application. Next, create the translations file under src/Locale/fr_FR/animals.yaml 738 Chapter 21. Internationalization & Localization CakePHP Cookbook Documentation, Release 3.10 // Prior to 3.5 use translator() I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 967 页 | 2.80 MB | 1 年前3
 CakePHP Cookbook 4.x
translation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); directory of your application. Next, create the translations file under resources/locales/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Cake\I18n\MessagesFileLoader as Loader; I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 1249 页 | 1.04 MB | 1 年前3 CakePHP Cookbook 4.x
translation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); directory of your application. Next, create the translations file under resources/locales/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Cake\I18n\MessagesFileLoader as Loader; I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 1249 页 | 1.04 MB | 1 年前3
 CakePHP Cookbook 4.x
translation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); } } The directory of your application. Next, create the translations file under resources/locales/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Cake\I18n\MessagesFileLoader as Loader; I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 967 页 | 2.88 MB | 1 年前3 CakePHP Cookbook 4.x
translation messages using YAML, you will first need to created the parser class: namespace App\I18n\Parser; class YamlFileParser { public function parse($file) { return yaml_parse_file($file); } } The directory of your application. Next, create the translations file under resources/locales/fr_FR/animals.yaml Dog: Chien Cat: Chat Bird: Oiseau And finally, configure the translation loader for the domain and Cake\I18n\MessagesFileLoader as Loader; I18n::setTranslator( 'animals', new Loader('animals', 'fr_FR', 'yaml'), 'fr_FR' ); Creating Generic Translators Configuring translators by calling I18n::setTranslator()0 码力 | 967 页 | 2.88 MB | 1 年前3
共 6 条
- 1














