2017 © Pedro Peláez
 

yii2-extension yii2-pages

A static pages module implements CRUD using Imperavi Redactor.

image

bupy7/yii2-pages

A static pages module implements CRUD using Imperavi Redactor.

  • Sunday, February 25, 2018
  • by bupy7
  • Repository
  • 4 Watchers
  • 13 Stars
  • 1,458 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 14 Forks
  • 1 Open issues
  • 11 Versions
  • 6 % Grown

The README.md

yii2-pages

Latest Stable Version Total Downloads Latest Unstable Version License Build Status Coverage Status, (*1)

A static pages module implements CRUD using Imperavi Redactor., (*2)

Installation

The preferred way to install this extension is through composer., (*3)

Either run, (*4)

php composer.phar require --prefer-dist bupy7/yii2-pages "*"

or add, (*5)

"bupy7/yii2-pages": "*"

to the require section of your composer.json file., (*6)

Installation

Add module in your config file:, (*7)

'bootstrap' => ['pages'],

...

'modules' => [
    ...

    'pages' => 'bupy7\pages\Module',
]

You must add the above config in your console config file to apply migrations., (*8)

By default module uses table name '{{%page}}'. If in your database this table is exist - change it adding to configuration of module new table name:, (*9)

'modules' => [
    ...

    'pages' => [
        'class' => 'bupy7\pages\Module',
        'tableName' => '{{%your_table_name}}',
    ],
]

Run migration, (*10)

./yii migrate/up --migrationPath=@bupy7/pages/migrations

Without module in console config file this command will throw an exception., (*11)

Usage

In module two controllers: default and manager., (*12)

manager need for control the pages out of the control panel. You need protect it controller via controllerMap or override it for add behavior with AccessControl., (*13)

Example:, (*14)

'modules' => [
    ...

    'pages' => [
        'class' => 'bupy7\pages\Module',

        ...

        'controllerMap' => [
            'manager' => [
                'class' => 'bupy7\pages\controllers\ManagerController',
                'as access' => [
                    'class' => AccessControl::className(),
                    'rules' => [
                        [
                            'allow' => true,
                            'roles' => ['admin'],
                        ],
                    ],
                ],
            ],
        ],
    ],
],

default for display of pages to site. You need add url rules to file of config for getting content via aliases pages., (*15)

Example:, (*16)

'urlManager' => [
    'rules' => [
        ...

        'pages/<page:[\w-]+>' => 'pages/default/index',
    ],
],

You can upload and add files/images via Imperavi Redactor, if enable it:, (*17)

'modules' => [
    ...

    'pages' => [
        'class' => 'bupy7\pages\Module',

        ...

        'pathToImages' => '@webroot/images',
        'urlToImages' => '@web/images',
        'pathToFiles' => '@webroot/files',
        'urlToFiles' => '@web/files',
        'uploadImage' => true,
        'uploadFile' => true,
        'addImage' => true,
        'addFile' => true,
    ],
],

Set up the custom language at Imperavi redactor:, (*18)

'modules' => [
    ...

    'pages' => [
        'class' => 'bupy7\pages\Module',
        'imperaviLanguage' => 'es',
    ],
]

There is all list a languages here: /vendor/vova07/yii2-imperavi-widget/src/assets/lang., (*19)

License

yii2-pages is released under the BSD 3-Clause License., (*20)

The Versions

25/02 2018

dev-master

9999999-dev https://github.com/bupy7/yii2-pages

A static pages module implements CRUD using Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

extension yii2 module pages static

25/02 2018

1.3.1

1.3.1.0 https://github.com/bupy7/yii2-pages

A static pages module implements CRUD using Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

extension yii2 module pages static

25/02 2018

1.3.0

1.3.0.0 https://github.com/bupy7/yii2-pages

A static pages module implements CRUD using Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

extension yii2 module pages static

25/02 2018

dev-dev

dev-dev https://github.com/bupy7/yii2-pages

A static pages module implements CRUD using Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

extension yii2 module pages static

08/04 2016

1.2.0

1.2.0.0 https://github.com/bupy7/yii2-pages

Module implements CRUD with static pages with uses Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

extension yii2 module pages static

06/04 2016

1.1.4

1.1.4.0 https://github.com/bupy7/yii2-pages

Module implements CRUD with static pages with uses Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

extension yii2 module pages static

22/03 2016

1.1.3

1.1.3.0 https://github.com/bupy7/yii2-pages

Module implements CRUD with static pages with uses Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

extension yii2 module pages static

11/03 2016

1.1.2

1.1.2.0 https://github.com/bupy7/yii2-pages

Module implements CRUD with static pages with uses Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

extension yii2 module pages static

07/03 2016

1.1.1

1.1.1.0 https://github.com/bupy7/yii2-pages

Module implements CRUD with static pages with uses Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

extension yii2 module pages static

29/12 2015

1.1.0

1.1.0.0 https://github.com/bupy7/yii2-pages

Module implements CRUD with static pages with uses Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

extension yii2 module pages static

04/05 2015

1.0.0

1.0.0.0 https://github.com/bupy7/yii2-pages

Module implements CRUD with static pages with uses Imperavi Redactor.

  Sources   Download

BSD-3-Clause

The Requires

 

extension yii2 module pages static