PHPackages                             liemuar/yii2-seo - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. liemuar/yii2-seo

ActiveYii2-extension[Utility &amp; Helpers](/categories/utility)

liemuar/yii2-seo
================

Модуль позволяет привязывать SEO поля к моделям

00PHP

Since Apr 29Pushed 4y agoCompare

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

READMEChangelogDependenciesVersions (2)Used By (0)

Yii2-seo
========

[](#yii2-seo)

Модуль дает возможность быстро присвоить и быстро распаковать СЕО поля: титл, дескрипшн, кейвордс (ТДК) и т.д.

Установка
---------

[](#установка)

Выполнить команду

```
php composer require liemuar/yii2-seo "*"

```

Или добавить в composer.json

```
"liemuar/yii2-seo": "*",

```

И выполнить

```
php composer update

```

Миграция:

```
php yii migrate --migrationPath=vendor/liemuar/yii2-seo/migrations

```

Использование
-------------

[](#использование)

К модели подключить поведение:

```
    function behaviors()
    {
        return [
            'seo' => [
                'class' => 'liemuar\seo\behaviors\SeoFields',
            ],
        ];
    }
```

Теперь все СЕО поля доступны при вызове $model-&gt;seo.

Пример использования во вью файле:

```
if(!$title = $model->seo->title) {
    $title = "Купить {$model->name} в Кургане в магазине «Шоп45»";
}

if(!$description = $model->seo->description) {
    $description = 'Страница '.$model->name;
}

if(!$keywords = $model->seo->keywords) {
    $keywords = '';
}

$this->title = $title;

$this->registerMetaTag([
    'name' => 'description',
    'content' => $description,
]);

$this->registerMetaTag([
    'name' => 'keywords',
    'content' => $keywords,
]);
```

Виджеты
-------

[](#виджеты)

Ввод СЕО полей:

```

```

Его необходимо вызвать внутри формы редактирования вашей модели.

###  Health Score

15

—

LowBetter than 3% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity0

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity28

Early-stage or recently created project

 Bus Factor1

Top contributor holds 61.1% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/f6425af3d8f26aa03a55d3fa843eb60b45f9caebf1e785c1cda0246645a89bf9?d=identicon)[liemuar](/maintainers/liemuar)

---

Top Contributors

[![pistol88](https://avatars.githubusercontent.com/u/8104605?v=4)](https://github.com/pistol88 "pistol88 (11 commits)")[![liemuar](https://avatars.githubusercontent.com/u/85555431?v=4)](https://github.com/liemuar "liemuar (7 commits)")

### Embed Badge

![Health badge](/badges/liemuar-yii2-seo/health.svg)

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

###  Alternatives

[mileschou/twnicip

Twnic IP

131.9k](/packages/mileschou-twnicip)

PHPackages © 2026

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