Palmabit-IT / multilanguage by palmabit

This package helps handling of language and translation with laravel framework
237
2
4
Package Data
Maintainer Username: palmabit
Maintainer Contact: j.beschi@palmabit.com (jacopo beschi)
Package Create Date: 2014-09-25
Package Last Update: 2016-02-15
Home Page: www.palmabit.com
Language: PHP
License: mit
Last Refreshed: 2024-11-22 03:14:05
Package Statistics
Total Downloads: 237
Monthly Downloads: 3
Daily Downloads: 0
Total Stars: 2
Total Watchers: 4
Total Forks: 0
Total Open Issues: 0

#Multilanguage

Build Status

##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:

  1. composer require "palmabit/multilanguage 1.0.*"
  2. Add to your service providers the following string: 'Palmabit\Multilanguage\MultilanguageServiceProvider'
  3. 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"
}