rikcage/yii2-sceditor

SCEditor, a lightweight WYSIWYG BBCode & HTML editor extension for Yii 2.0 Framework

Installs: 44

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 0

Forks: 0

Open Issues: 0

Language:JavaScript

Type:yii2-extension

0.0.1 2018-12-11 12:28 UTC

This package is auto-updated.

Last update: 2024-04-12 04:09:45 UTC


README

SCEditor, a lightweight WYSIWYG BBCode & HTML editor extension for Yii 2.0 Framework

Installation

The preferred way to install this extension is through composer.

To install, either run

$ php composer.phar require rikcage/yii2-sceditor "*"

or add

"rikcage/yii2-sceditor": "*"

to the require section of your composer.json file.

Usage

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

use rikcage\sceditor\SCEditor;

<?= $form->field($model, 'text')->widget(SCEditor::className(), [
        'options' => ['rows' => 6],
        'clientOptions' => [
            'format' => 'bbcode',
        ]
    ]) ?>

or

use rikcage\sceditor\SCEditor;

<?= $form->field($model, 'text')->widget(SCEditor::className(), [
        'options' => ['rows' => 6],
        'clientOptions' => [
            'format' => 'xhtml',
        ]
    ]) ?>

Further Information

Please, check the SCEditor plugin site documentation for further information about its configuration options.