CKEditor form element.
Allows setting path to ckeditor files and setting config variables. Default config is to have bbcode output and only a small subset of available buttons on the toolbars.
package | Gems |
---|---|
subpackage | Form |
author | Menno Dekker |
copyright | Copyright (c) 2014 Erasmus MC |
license | New BSD License |
version | $Id$ |
__construct(string|array|\Zend_Config $spec, array|\Zend_Config $options = null
) : void
$spec may be:
string
array
\Zend_Config
array
\Zend_Config
\Zend_Form_Exception |
if no element name after initialization |
---|
init()
loadDefaultDecorators() : \Zend_Form_Element
\Zend_Form_Element
setBasePath(string $basePath) : \CKEditor_Form_CKEditor
string
\CKEditor_Form_CKEditor
setCKConfig(string|array $key, mixed $value = null
)
ARRAY Use array as first parameter to set all items at once. This will overwrite the existing config. Use false as second parameter to ADD to the existing config
STRING or use a string to set items one by one, the second parameter is the value
string
array
mixed
setView(\Zend_View_Interface $view = null
) : \CKEditor_Form_CKEditor
Ensures that the view object has the CKEditor view helper path set.
\Zend_View_Interface
\CKEditor_Form_CKEditor
addClass(string $addClass)
string
the Class or classes to add, seperated by spaces
$basePath : string
''
$config : array
array('extraPlugins' => 'bbcode', 'toolbar' => array(array('Source', '-', 'Undo', 'Redo'), array('Find', 'Replace', '-', 'SelectAll', 'RemoveFormat'), array('Link', 'Unlink', 'Image', 'SpecialChar'), '/', array('Bold', 'Italic', 'Underline'), array('NumberedList', 'BulletedList', '-', 'Blockquote'), array('Maximize')))
$helper : string
'formCKEditor'
$_elementClass : string
'form-control'