TinyMce Widget

Visit GitHub Repository

What is the TinyMce Widget?

The TinyMce widget allows to you use the amazing WYSIWYG TinyMce plugin on your forms.


The preferred way to install this extension is through composer.

Either run

php composer.phar require "2amigos/yii2-tinymce-widget" "*"

or add the following to the require section of your application's composer.json file:

"2amigos/yii2-tinymce-widget" : "*" 

Usage example

use dosamigos\tinymce\TinyMce;

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


Thanks All