palmabit/multilanguage
Composer 安装命令:
composer require palmabit/multilanguage
包简介
This package helps handling of language and translation with laravel framework
README 文档
README
#Multilanguage
##Description
This package adds multilanguage capability to your laravel app.
Installation
The simplest method of installation is to install it as a global Composer package:
- composer require
"palmabit/multilanguage 1.0.*" - Add to your service providers the following string:
'Palmabit\Multilanguage\MultilanguageServiceProvider' - Run the following command:
"php artisan asset:publish"
Docs
In order to see the docs install the laravel package example app: https://github.com/Palmabit-IT/package-examples
API REST
GET current language
http://<url>/api/v1/lang
response:
{
"lang": "en"
}
Set new language (PUT)
http://<url>/api/v1/lang/<new-lang>
response:
{
"success": true
"lang": "en"
}
Set new language (POST)
http://<url>/api/v1/lang
parameters:
{
"lang": "en"
}
response:
{
"success": true
"lang": "en"
}
统计信息
- 总下载量: 239
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 2
- 依赖项目数: 3
- 推荐数: 0
其他信息
- 授权协议: mit
- 更新时间: 2014-10-04