powerkernel/yii2-tinymce

TinyMCE widget for Yii2.

Installs: 1 310

Dependents: 4

Suggesters: 0

Security: 0

Stars: 2

Watchers: 2

Forks: 48

Language:JavaScript

Type:yii2-extension

2.0.5 2018-11-17 09:50 UTC

This package is auto-updated.

Last update: 2024-04-18 01:47:32 UTC


README

forked from 2amigos/yii2-tinymce-widget

Installation

The preferred way to install this extension is through composer.

Either run

composer require powerkernel/yii2-tinymce "*"

or add

"powerkernel/yii2-tinymce": "*"

to the require section of your application's composer.json file.

Usage

use powerkernel\tinymce\TinyMce;

<?= $form->field($model, 'text')->widget(TinyMce::class, []);?>

Custom Options

<?= $form->field($model, 'text')->widget(TinyMce::class, [
    'options' => ['rows' => 6],
    'clientOptions' => [
        'height'=>320,
        'menubar'=> true,
        'plugins' => [
            "advlist autolink lists link charmap print preview anchor",
            "searchreplace visualblocks code fullscreen",
            "insertdatetime media table contextmenu paste image"
        ],
        'toolbar' => "undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | link image | removeformat code"
    ]    
]);?>