PHPackages                             omcrn/yii2-i18ncontent - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Localization &amp; i18n](/categories/localization)
4. /
5. omcrn/yii2-i18ncontent

ActiveLibrary[Localization &amp; i18n](/categories/localization)

omcrn/yii2-i18ncontent
======================

Show text widgets, pages, articles in chosen language

v2.0.3(7y ago)1511[4 issues](https://github.com/omcrn/yii2-i18ncontent/issues)PHPPHP &gt;=5.4.0

Since Dec 26Pushed 7y ago3 watchersCompare

[ Source](https://github.com/omcrn/yii2-i18ncontent)[ Packagist](https://packagist.org/packages/omcrn/yii2-i18ncontent)[ RSS](/packages/omcrn-yii2-i18ncontent/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (10)Dependencies (7)Versions (52)Used By (0)

i18n content module for Yii2 framework
======================================

[](#i18n-content-module-for-yii2-framework)

yii2-i18ncontent is yii2 module for creating several types of contents in different languages. It support creating the following contents:

- Translatable article categories and articles
- Translatable Pages
- Carousels with translatable caption texts
- Translatable portions of text.
- Menu contents (Non translatable yet)

### Installation

[](#installation)

1. Run `composer require omcrn/yii2-i18ncontent` or add `"omcrn/yii2-i18ncontent": "~2.0.0"` in your projects `composer.json`.
2. Make sure you have `user` table in your database with primary key `id`.
3. Run migrations to create tables by `php console/yii migrate --migrationPath=@yii/i18n/migrations` from projects root directory
4. Run migrations to create tables by `php console/yii migrate --migrationPath=@vendor/omcrn/yii2-i18ncontent/migrations` from projects root directory

### Configuration

[](#configuration)

Add the following code in projects configuration file under `modules` section

```
'i18ncontent' => [
    'class' => 'centigen\i18ncontent\Module',
    'defaultLayout' => '/admin', //Default layout which will be used for rendering i18ncontent pages
],
```

Add the following code in project's configuration file under `components` section

```
"i18n" => [
    "translations" => [
        '...',
        'i18ncontent' => [
            'class' => 'yii\i18n\PhpMessageSource',
            'basePath' => '@vendor/omcrn/yii2-i18ncontent/messages',
        ],
    ]
]
'formatter' => [
    'class' => 'centigen\base\i18n\Formatter'
],
'i18ncontent' => [
    'class' => 'centigen\i18ncontent\I18nContent',
    'userClass' => 'common\models\User', //User model class. If you do not have user model, generate it from user table. Make sure this models extends \yii\db\ActiveRecord class
    'mediaUrlPrefix' => null, //In texts which may contain  or other media object tags (texts which come from WYSIWYG editors)
                             // `$mediaUrlPrefix` strings are replaced with `$mediaUrlReplacement` string when calling `Html::encodeMediaItemUrls`
                             // and vice versa when calling `Html::decodeMediaItemUrls`
    'mediaUrlReplacement' => '{{media_item_url_prefix}}' //See `$mediaUrlPrefix`
],
```

Add `availableLocales` array to application configuration `params` array.

For each language listed here tab will be displayed to provide content.

```
'params' => [
    '...',
    'availableLocales' => [
        'en-US' => 'English',
        'ru-RU' => 'Русский'
        ...
    ],
]
```

### Urls for administration

[](#urls-for-administration)

Append the following urls to the domain to see administration pages

ContentUrlArticle categoriesi18ncontent/article-category/indexArticlesi18ncontent/article/indexPagesi18ncontent/page/indexText widgetsi18ncontent/widget-text/indexCarouselsi18ncontent/widget-carousel/indexMenusi18ncontent/widget-menu/index

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity71

Established project with proven stability

 Bus Factor1

Top contributor holds 63% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~13 days

Recently: every ~52 days

Total

50

Last Release

2793d ago

Major Versions

v0.3.6 → 1.0.02017-01-26

1.2.3 → v2.0.02018-03-24

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/47417401?v=4)[Zura Sekhniashvili](/maintainers/arboshiki)[@arboshiki](https://github.com/arboshiki)

---

Top Contributors

[![thecodeholic](https://avatars.githubusercontent.com/u/4627922?v=4)](https://github.com/thecodeholic "thecodeholic (102 commits)")[![keshikashviligio](https://avatars.githubusercontent.com/u/6962834?v=4)](https://github.com/keshikashviligio "keshikashviligio (25 commits)")[![guga-grigolia](https://avatars.githubusercontent.com/u/4057809?v=4)](https://github.com/guga-grigolia "guga-grigolia (16 commits)")[![saiat3](https://avatars.githubusercontent.com/u/17884566?v=4)](https://github.com/saiat3 "saiat3 (11 commits)")[![sleemy1997](https://avatars.githubusercontent.com/u/36790954?v=4)](https://github.com/sleemy1997 "sleemy1997 (7 commits)")[![bmuradashvili](https://avatars.githubusercontent.com/u/25098135?v=4)](https://github.com/bmuradashvili "bmuradashvili (1 commits)")

---

Tags

cmsyii2modulei18n articlesi18n carouselsi18n pages

### Embed Badge

![Health badge](/badges/omcrn-yii2-i18ncontent/health.svg)

```
[![Health](https://phpackages.com/badges/omcrn-yii2-i18ncontent/health.svg)](https://phpackages.com/packages/omcrn-yii2-i18ncontent)
```

###  Alternatives

[lajax/yii2-translate-manager

Translation management extension for Yii 2

227578.8k13](/packages/lajax-yii2-translate-manager)[yii2-starter-kit/yii2-starter-kit

Yii2 Starter Kit Application Template

1.4k6.6k](/packages/yii2-starter-kit-yii2-starter-kit)[tigrov/yii2-country

Country data for Yii2 using Intl extension and more.

151.1k](/packages/tigrov-yii2-country)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
