Laravel MULT package to content manage with different languages

Laravel Multilingual Tools

MULT - Package for the Laravel framework to content manage with different languages.

For example, you can store pages in English, Russian, French, German and some another languages...

It is you who add new languages to your application.

All multilingual fields will be with a language postfix, as in example:

title_en, description_en, content_en

title_ru, description_ru, content_ru, e t. c.

To manage the languages and content themselves, you need to create CRUD elements in your application by yourself.

This package provides:

  • Base class for migrations, which allows you to automatically create a bunch of tables "main table" + "translation table".
  • Trait for basic models. Provides getting the translation of a multilingual attribute from the translation table using special logic built into the __get () magic method. Allows you to set a new value for a multilingual attribute using special logic built into the __set () magic method.
  • Language migration and language model.

 

Table structure example.

Main pages table:

Main pages table

Translate table:

Translate table

Languages table:

Languages table

Documentation on GitHub