paliari/php-i18n
最新稳定版本:1.2.0
Composer 安装命令:
composer require paliari/php-i18n
包简介
README 文档
README
Installation
$ composer require paliari/php-i18n
Configuration
Create your yml locale files inside some folder in your project. See the yml file example:
pt-BR: hello: Olá I18n user: name: Nome do usuário errors: messages: unauthorized: Não autorizado
You can use multiple languages and multiple files for each language, ex:
- pt-BR.yml
- models.pt-BR.yml
- errors.pt-BR.yml
- en.yml
- models.en.yml
- errors.en.yml
Say to the plugin where this files were placed
\Paliari\I18n::instance()->addLocalesPath(__DIR__ . '/config/locales')->setCurrentLocale('pt-BR');
Usage
Paliari\I18n::instance()->hum('hello');
Authors
统计信息
- 总下载量: 3.36k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 0
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-09-15