PHP Class CI_Jquery, TastyIgniter

Inheritance: extends CI_Javascript
Datei anzeigen Open project: tastyigniter/tastyigniter

Public Properties

Property Type Description
$jquery_ajax_img string JQuery AJAX image
$jquery_code_for_compile array JQuery code for compile
$jquery_code_for_load array JQuery code for load
$jquery_corner_active boolean JQuery corner active flag
$jquery_table_sorter_active boolean JQuery table sorter active flag
$jquery_table_sorter_pager_active boolean JQuery table sorter pager active

Protected Properties

Property Type Description
$_javascript_folder string JavaScript directory location

Public Methods

Method Description
__construct ( array $params ) : void Constructor
corner ( string $element = '', string $corner_style = '' ) : string Corner Plugin
effect ( string $src, boolean $relative = FALSE ) : void Effect
modal ( string $src, boolean $relative = FALSE ) : void Modal window
plugin ( string $src, boolean $relative = FALSE ) : void Plugin
script ( string $library_src = '', boolean $relative = FALSE ) : string Script Tag
sortable ( string $element, array $options = [] ) : string Sortable
tablesorter ( $table = '', $options = '' ) : string Table Sorter Plugin
ui ( string $src, boolean $relative = FALSE ) : void UI

Protected Methods

Method Description
_addClass ( string $element = 'this', string $class = '' ) : string Add Class
_add_event ( $element, $js, $event ) : string Add Event
_animate ( string $element = 'this', array $params = [], string $speed = '', string $extra = '' ) : string Animate
_blur ( $element = 'this', $js = '' ) : string Blur
_change ( $element = 'this', $js = '' ) : string Change
_clear_compile ( ) : void Clear Compile
_click ( $element = 'this', $js = '', $ret_false = TRUE ) : string Click
_compile ( string $view_var = 'script_foot', boolean $script_tags = TRUE ) : void Compile
_dblclick ( $element = 'this', $js = '' ) : string Double Click
_document_ready ( array $js ) : void Document Ready
_error ( $element = 'this', $js = '' ) : string Error
_fadeIn ( $element = 'this', $speed = '', $callback = '' ) : string Fade In
_fadeOut ( $element = 'this', $speed = '', $callback = '' ) : string Fade Out
_focus ( $element = 'this', $js = '' ) : string Focus
_hide ( $element = 'this', $speed = '', $callback = '' ) : string Hide
_hover ( $element = 'this', $over = '', $out = '' ) : string Hover
_keydown ( $element = 'this', $js = '' ) : string Keydown
_keyup ( $element = 'this', $js = '' ) : string Keyup
_load ( $element = 'this', $js = '' ) : string Load
_mousedown ( $element = 'this', $js = '' ) : string Mousedown
_mouseout ( $element = 'this', $js = '' ) : string Mouse Out
_mouseover ( $element = 'this', $js = '' ) : string Mouse Over
_mouseup ( $element = 'this', $js = '' ) : string Mouseup
_output ( array $array_js = [] ) : void Output
_prep_element ( $element ) : string Prep Element
_removeClass ( string $element = 'this', string $class = '' ) : string Remove Class
_resize ( $element = 'this', $js = '' ) : string Resize
_scroll ( $element = 'this', $js = '' ) : string Scroll
_show ( $element = 'this', $speed = '', $callback = '' ) : string Show
_slideDown ( $element = 'this', $speed = '', $callback = '' ) : string Slide Down
_slideToggle ( $element = 'this', $speed = '', $callback = '' ) : string Slide Toggle
_slideUp ( $element = 'this', $speed = '', $callback = '' ) : string Slide Up
_toggle ( $element = 'this' ) : string Toggle
_toggleClass ( string $element = 'this', string $class = '' ) : string Toggle Class
_unload ( $element = 'this', $js = '' ) : string Unload
_updater ( $container = 'this', $controller = '', $options = '' ) : string Updater
_validate_speed ( $speed ) : string Validate Speed
_zebraTables ( string $class = '', string $odd = 'odd', string $hover = '' ) : string Zebra tables

Method Details

__construct() public method

Constructor
public __construct ( array $params ) : void
$params array
return void

_addClass() protected method

Outputs a jQuery addClass event
protected _addClass ( string $element = 'this', string $class = '' ) : string
$element string
$class string
return string

_add_event() protected method

Constructs the syntax for an event, and adds to into the array for compilation
protected _add_event ( $element, $js, $event ) : string
return string

_animate() protected method

Outputs a jQuery animate event
protected _animate ( string $element = 'this', array $params = [], string $speed = '', string $extra = '' ) : string
$element string
$params array
$speed string 'slow', 'normal', 'fast', or time in milliseconds
$extra string
return string

_blur() protected method

Outputs a jQuery blur event
protected _blur ( $element = 'this', $js = '' ) : string
return string

_change() protected method

Outputs a jQuery change event
protected _change ( $element = 'this', $js = '' ) : string
return string

_clear_compile() protected method

Clears the array of script events collected for output
protected _clear_compile ( ) : void
return void

_click() protected method

Outputs a jQuery click event
protected _click ( $element = 'this', $js = '', $ret_false = TRUE ) : string
return string

_compile() protected method

As events are specified, they are stored in an array This function compiles them all for output on a page
protected _compile ( string $view_var = 'script_foot', boolean $script_tags = TRUE ) : void
$view_var string
$script_tags boolean
return void

_dblclick() protected method

Outputs a jQuery dblclick event
protected _dblclick ( $element = 'this', $js = '' ) : string
return string

_document_ready() protected method

A wrapper for writing document.ready()
protected _document_ready ( array $js ) : void
$js array
return void

_error() protected method

Outputs a jQuery error event
protected _error ( $element = 'this', $js = '' ) : string
return string

_fadeIn() protected method

Outputs a jQuery hide event
protected _fadeIn ( $element = 'this', $speed = '', $callback = '' ) : string
return string

_fadeOut() protected method

Outputs a jQuery hide event
protected _fadeOut ( $element = 'this', $speed = '', $callback = '' ) : string
return string

_focus() protected method

Outputs a jQuery focus event
protected _focus ( $element = 'this', $js = '' ) : string
return string

_hide() protected method

Outputs a jQuery hide action
protected _hide ( $element = 'this', $speed = '', $callback = '' ) : string
return string

_hover() protected method

Outputs a jQuery hover event
protected _hover ( $element = 'this', $over = '', $out = '' ) : string
return string

_keydown() protected method

Outputs a jQuery keydown event
protected _keydown ( $element = 'this', $js = '' ) : string
return string

_keyup() protected method

Outputs a jQuery keydown event
protected _keyup ( $element = 'this', $js = '' ) : string
return string

_load() protected method

Outputs a jQuery load event
protected _load ( $element = 'this', $js = '' ) : string
return string

_mousedown() protected method

Outputs a jQuery mousedown event
protected _mousedown ( $element = 'this', $js = '' ) : string
return string

_mouseout() protected method

Outputs a jQuery mouseout event
protected _mouseout ( $element = 'this', $js = '' ) : string
return string

_mouseover() protected method

Outputs a jQuery mouseover event
protected _mouseover ( $element = 'this', $js = '' ) : string
return string

_mouseup() protected method

Outputs a jQuery mouseup event
protected _mouseup ( $element = 'this', $js = '' ) : string
return string

_output() protected method

Outputs script directly
protected _output ( array $array_js = [] ) : void
$array_js array = array()
return void

_prep_element() protected method

Puts HTML element in quotes for use in jQuery code unless the supplied element is the Javascript 'this' object, in which case no quotes are added
protected _prep_element ( $element ) : string
return string

_removeClass() protected method

Outputs a jQuery remove class event
protected _removeClass ( string $element = 'this', string $class = '' ) : string
$element string
$class string
return string

_resize() protected method

Outputs a jQuery resize event
protected _resize ( $element = 'this', $js = '' ) : string
return string

_scroll() protected method

Outputs a jQuery scroll event
protected _scroll ( $element = 'this', $js = '' ) : string
return string

_show() protected method

Outputs a jQuery show event
protected _show ( $element = 'this', $speed = '', $callback = '' ) : string
return string

_slideDown() protected method

Outputs a jQuery slideDown event
protected _slideDown ( $element = 'this', $speed = '', $callback = '' ) : string
return string

_slideToggle() protected method

Outputs a jQuery slideToggle event
protected _slideToggle ( $element = 'this', $speed = '', $callback = '' ) : string
return string

_slideUp() protected method

Outputs a jQuery slideUp event
protected _slideUp ( $element = 'this', $speed = '', $callback = '' ) : string
return string

_toggle() protected method

Outputs a jQuery toggle event
protected _toggle ( $element = 'this' ) : string
return string

_toggleClass() protected method

Outputs a jQuery toggle class event
protected _toggleClass ( string $element = 'this', string $class = '' ) : string
$element string
$class string
return string

_unload() protected method

Outputs a jQuery unload event
protected _unload ( $element = 'this', $js = '' ) : string
return string

_updater() protected method

An Ajax call that populates the designated DOM node with returned content
protected _updater ( $container = 'this', $controller = '', $options = '' ) : string
return string

_validate_speed() protected method

Ensures the speed parameter is valid for jQuery
protected _validate_speed ( $speed ) : string
return string

_zebraTables() protected method

Zebra tables
protected _zebraTables ( string $class = '', string $odd = 'odd', string $hover = '' ) : string
$class string
$odd string
$hover string
return string

corner() public method

Corner Plugin
public corner ( string $element = '', string $corner_style = '' ) : string
$element string
$corner_style string
return string

effect() public method

Load an Effect library
public effect ( string $src, boolean $relative = FALSE ) : void
$src string
$relative boolean
return void

modal() public method

Load a thickbox modal window
public modal ( string $src, boolean $relative = FALSE ) : void
$src string
$relative boolean
return void

plugin() public method

Load a plugin library
public plugin ( string $src, boolean $relative = FALSE ) : void
$src string
$relative boolean
return void

script() public method

Outputs the script tag that loads the jquery.js file into an HTML document
public script ( string $library_src = '', boolean $relative = FALSE ) : string
$library_src string
$relative boolean
return string

sortable() public method

Creates a jQuery sortable
public sortable ( string $element, array $options = [] ) : string
$element string
$options array
return string

tablesorter() public method

Table Sorter Plugin
public tablesorter ( $table = '', $options = '' ) : string
return string

ui() public method

Load a user interface library
public ui ( string $src, boolean $relative = FALSE ) : void
$src string
$relative boolean
return void

Property Details

$_javascript_folder protected_oe property

JavaScript directory location
protected string $_javascript_folder
return string

$jquery_ajax_img public_oe property

JQuery AJAX image
public string $jquery_ajax_img
return string

$jquery_code_for_compile public_oe property

JQuery code for compile
public array $jquery_code_for_compile
return array

$jquery_code_for_load public_oe property

JQuery code for load
public array $jquery_code_for_load
return array

$jquery_corner_active public_oe property

JQuery corner active flag
public bool $jquery_corner_active
return boolean

$jquery_table_sorter_active public_oe property

JQuery table sorter active flag
public bool $jquery_table_sorter_active
return boolean

$jquery_table_sorter_pager_active public_oe property

JQuery table sorter pager active
public bool $jquery_table_sorter_pager_active
return boolean