albertgeeca/yii2-language-manager

Language manager for Yii2 framework. Allows to add languages that can be used in other extensions.


Keywords
locale, extension, language, yii2
License
GPL-3.0

Documentation

Yii2 Language Manager

Language manager for Yii2 framework. Allows to add languages that can be used in other extensions.

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist albertgeeca/yii2-language-manager "*"

or add

"albertgeeca/yii2-language-manager": "*"

to the require section of your composer.json file.

Apply migrations:

php yii migrate --migrationPath=@vendor/albertgeeca/yii2-language-manager/src/migrations

To access the module, you need to add this to your application configuration:

    ......
    'modules' => [
        'language' => [
            'class' => 'albertgeeca\language_manager\src\backend\Module',
        ],
    ],
    ......

Usage

Once the extension is installed, simply use it in your code by :

<?= \albertgeeca\language_manager\AutoloadExample::widget(); ?>```