Horde_Editor
in package
The Horde_Editor:: package provides an API to generate the code necessary for embedding javascript RTE editors in a web page.
Tags
Table of Contents
- $_browser : Horde_Browser
- A browser detection object.
- $_js : string
- Javascript code to init the editor.
- __construct() : mixed
- Constructor.
- getJS() : array<string|int, mixed>
- Returns the JS code needed to instantiate the editor.
- initialize() : mixed
- Initialize the editor.
- supportedByBrowser() : bool
- Does the current browser support the Horde_Editor driver.
Properties
$_browser
A browser detection object.
protected
Horde_Browser
$_browser
$_js
Javascript code to init the editor.
protected
string
$_js
= ''
Methods
__construct()
Constructor.
public
__construct(Horde_Browser $browser) : mixed
Parameters
- $browser : Horde_Browser
Return values
mixed —getJS()
Returns the JS code needed to instantiate the editor.
public
getJS() : array<string|int, mixed>
Return values
array<string|int, mixed> —Two keys:
- files: (array) Javascript files that need to be loaded by browser.
- scrips: (array) Code that needs to be run on the browser.
initialize()
Initialize the editor.
public
initialize([array<string|int, mixed> $params = array() ]) : mixed
Parameters
- $params : array<string|int, mixed> = array()
-
Additional parameters.
Return values
mixed —supportedByBrowser()
Does the current browser support the Horde_Editor driver.
public
supportedByBrowser() : bool
Return values
bool —True if the browser supports the editor.