class JHtmlBehavior


Located at : UKNOWVA_ROOT/libraries/joomla/html/html/behavior.php

Utility class for javascript behaviors

Methods

static void
framework(string $extras = true, boolean $debug = null)

Method to load the MooTools framework into the document head

static void
mootools(boolean $debug = null) deprecated

Deprecated. Use JHtmlBehavior::framework() instead.

static void
caption()

Add unobtrusive javascript support for image captions.

static void
formvalidation()

Add unobtrusive javascript support for form validation.

static void
switcher()

Add unobtrusive javascript support for submenu switcher support in Global Configuration and System Information.

static void
combobox()

Add unobtrusive javascript support for a combobox effect.

static void
tooltip(string $selector = '.hasTip', array $params = array())

Add unobtrusive javascript support for a hover tooltips.

static void
modal(string $selector = 'a.modal', array $params = array())

Add unobtrusive javascript support for modal links.

static void
multiselect()

JavaScript behavior to allow shift select in grids

static void
uploader(string $id = 'file-upload', array $params = array(), string $upload_queue = 'upload-queue')

Add unobtrusive javascript support for the advanced uploader.

static void
tree($id, $params = array(), $root = array())

Add unobtrusive javascript support for a collapsible tree.

static void
calendar()

Add unobtrusive javascript support for a calendar control.

static void
keepalive()

Keep session alive, for example, while editing or creating an article.

static void
noframes($location = 'top.location.href')

Break us out of any containing iframes

Details

at line 33
static void framework(string $extras = true, boolean $debug = null)

Method to load the MooTools framework into the document head

If debugging mode is on an uncompressed version of MooTools is included for easier debugging.

Parameters

string $extras MooTools file to load
boolean $debug Is debugging mode on? [optional]

Return Value

void

at line 75
static void mootools(boolean $debug = null) deprecated

deprecated 12.1

Deprecated. Use JHtmlBehavior::framework() instead.

Parameters

boolean $debug Is debugging mode on? [optional]

Return Value

void

at line 87
static void caption()

Add unobtrusive javascript support for image captions.

Return Value

void

at line 116
static void formvalidation()

Add unobtrusive javascript support for form validation.

To enable form validation the form tag must have class="form-validate". Each field that needs to be validated needs to have class="validate". Additional handlers can be added to the handler for username, password, numeric and email. To use these add class="validate-email" and so on.

Return Value

void

at line 141
static void switcher()

Add unobtrusive javascript support for submenu switcher support in Global Configuration and System Information.

Return Value

void

at line 180
static void combobox()

Add unobtrusive javascript support for a combobox effect.

Note that this control is only reliable in absolutely positioned elements. Avoid using a combobox in a slider or dynamic pane.

Return Value

void

at line 222
static void tooltip(string $selector = '.hasTip', array $params = array())

Add unobtrusive javascript support for a hover tooltips.

Add a title attribute to any element in the form title="title::text"

Uses the core Tips class in MooTools.

Parameters

string $selector The class selector for the tooltip.
array $params An array of options for the tooltip. Options for the tooltip can be: - maxTitleChars integer The maximum number of characters in the tooltip title (defaults to 50). - offsets object The distance of your tooltip from the mouse (defaults to {'x': 16, 'y': 16}). - showDelay integr The millisecond delay the show event is fired (defaults to 100). - hideDelay integer The millisecond delay the hide hide is fired (defaults to 100). - className string The className your tooltip container will get. - fixed boolean If set to true, the toolTip will not follow the mouse. - onShow function The default function for the show event, passes the tip element and the currently hovered element. - onHide function The default function for the hide event, passes the currently hovered element.

Return Value

void

at line 296
static void modal(string $selector = 'a.modal', array $params = array())

Add unobtrusive javascript support for modal links.

Parameters

string $selector The class selector for which a modal behaviour is to be applied.
array $params An array of parameters for the modal behaviour. Options for the modal behaviour can be: - ajaxOptions - size - shadow - onOpen - onClose - onUpdate - onResize - onShow - onHide

Return Value

void

at line 387
static void multiselect()

JavaScript behavior to allow shift select in grids

Return Value

void

at line 407
static void uploader(string $id = 'file-upload', array $params = array(), string $upload_queue = 'upload-queue')

Add unobtrusive javascript support for the advanced uploader.

Parameters

string $id
array $params An array of options for the uploader.
string $upload_queue

Return Value

void

at line 566
static void tree($id, $params = array(), $root = array())

Add unobtrusive javascript support for a collapsible tree.

Parameters

$id string
$params array An array of options.
$root array

Return Value

void

at line 633
static void calendar()

Add unobtrusive javascript support for a calendar control.

Return Value

void

at line 667
static void keepalive()

Keep session alive, for example, while editing or creating an article.

Return Value

void

at line 715
static void noframes($location = 'top.location.href')

Break us out of any containing iframes

Parameters

$location

Return Value

void