Sywooch / yii2-nsblog

Nested sets blog for Yii2 (multilanguage, multidomain)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Blog extension for Yii2

Nested category, post for multilanguage, multidomain site

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist koperdog/yii2-nsblog "*"

or add

"koperdog/yii2-nsblog": "*"

to the require section of your composer.json file.

and add the module to backend config:

'modules' => [
    //...
    'blog' => [
        'class' => 'koperdog\yii2nsblog\backend\Module',
    ],
    //...
],

Also you need add the module to frontend config:

'modules' => [
    //...
    'blog' => [
        'class' => 'koperdog\yii2nsblog\frontend\Module',
    ],
    //...
],
'urlManager' => [
    'rules' => [
        [
            'class' => 'koperdog\yii2nsblog\components\CategoryUrlRule',
            //'prefix' => 'blog'
        ],
        [
            'class' => 'koperdog\yii2nsblog\components\PageUrlRule',
            //'prefix' => 'blog'
        ],
    ],
],

Then you should start the migration (console):

php yii migrate --migrationPath=@vendor/koperdog/yii2-nsblog/migrations

Usage

Go to backend /blog/categories or /blog/pages

Also you can clone this repository for create your extension (for example, a store, etc.)

About

Nested sets blog for Yii2 (multilanguage, multidomain)

License:Apache License 2.0


Languages

Language:PHP 95.8%Language:JavaScript 3.2%Language:CSS 1.0%