\TrumbowygHTMLEditorField
A simple WYSIWYG HTML editor field that can be used to add basic HTML editing capabilities to a Silverstripe site.
At the moment this is designed to only be used in a front end form,
it would be nice to add support for the CMS however, and this will be
a future development.
Some of this code has been taken from the Silverstripe HTMLEditor
field
Synopsis
class TrumbowygHTMLEditorField
extends TextareaField
{
- // members
- private static bool $sanitise_server_side = false;
- private static array $default_buttons = ;
- protected integer $rows = 30;
- protected array $buttons = ;
- // methods
- public array getButtons()
- public Object setButtons()
- public Object addButton()
- public array getButtonsJS()
- public void __construct()
- public string Field()
- public void saveInto()
- public HtmlEditorField_Readonly performReadonlyTransformation()
- public void performDisabledTransformation()
Hierarchy
Extends
- TextareaField
Members
Methods
public
- __construct()
- Field()
- addButton() — Set our array of buttons
- getButtons() — Get all the current buttons
- getButtonsJS() — Get all the current buttons rendered as a string for JS
- performDisabledTransformation()
- performReadonlyTransformation()
- saveInto()
- setButtons() — Set our array of buttons