THE best WYSIWYG editor with instant integration

This is the wrapper around the CKEditor.

Basic example of usage is this:

        'name' => 'some_text_field'

Note We included the most feature-packed variant of CKEditor. If you want a simpler version, you have to trim it, removing unnecessary plugins on widget invocation.

Here's all configuration properties which you can set for TbCKEditor.

Most of them are common to all form input widgets.

model CModel = null

The data model associated with this widget. See CInputWidget.model. Either this property along with attribute should be defined, or the name.

attribute string = null

If you set the model attribute, here you have to specify the name of the model property which you want to change with this widget. See CInputWidget.attribute. Either this property along with model should be defined, or the name.

name string = null

The value of name HTML attribute of the input element. It must be set if you did not provide value for model. See CInputWidget.name. Either this property should be defined, or the model together with attribute.

value string = null

Here you can force the initial value of the input. If model is provided, by default model's value is used. See CInputWidget.value.

htmlOptions array = array()

HTML attributes of the input tag itself. Please note that it is not the attributes of a wrapper tag around the input. See CInputWidget.htmlOptions.

editorOptions array = array()

Options for the original library. This value will be JSON-encoded and fed to CKEditor. See the library documentation for list of all possible options.

Basic buttons only

        'name' => 'some_random_text_field',
        'editorOptions' => array(
            // From basic `build-config.js` minus 'undo', 'clipboard' and 'about'
            'plugins' => 'basicstyles,toolbar,enterkey,entities,floatingspace,wysiwygarea,indentlist,link,list,dialog,dialogui,button,indent,fakeobjects'