My Project
 All Data Structures Namespaces Functions Variables
Public Member Functions | Data Fields
CI_Jquery Class Reference
Inheritance diagram for CI_Jquery:
CI_Javascript

Public Member Functions

 __construct ($params)
 
 _blur ($element= 'this', $js= '')
 
 _change ($element= 'this', $js= '')
 
 _click ($element= 'this', $js= '', $ret_false=TRUE)
 
 _dblclick ($element= 'this', $js= '')
 
 _error ($element= 'this', $js= '')
 
 _focus ($element= 'this', $js= '')
 
 _hover ($element= 'this', $over, $out)
 
 _keydown ($element= 'this', $js= '')
 
 _keyup ($element= 'this', $js= '')
 
 _load ($element= 'this', $js= '')
 
 _mousedown ($element= 'this', $js= '')
 
 _mouseout ($element= 'this', $js= '')
 
 _mouseover ($element= 'this', $js= '')
 
 _mouseup ($element= 'this', $js= '')
 
 _output ($array_js= '')
 
 _resize ($element= 'this', $js= '')
 
 _scroll ($element= 'this', $js= '')
 
 _unload ($element= 'this', $js= '')
 
 _addClass ($element= 'this', $class='')
 
 _animate ($element= 'this', $params=array(), $speed= '', $extra= '')
 
 _fadeIn ($element= 'this', $speed= '', $callback= '')
 
 _fadeOut ($element= 'this', $speed= '', $callback= '')
 
 _hide ($element= 'this', $speed= '', $callback= '')
 
 _removeClass ($element= 'this', $class='')
 
 _slideUp ($element= 'this', $speed= '', $callback= '')
 
 _slideDown ($element= 'this', $speed= '', $callback= '')
 
 _slideToggle ($element= 'this', $speed= '', $callback= '')
 
 _toggle ($element= 'this')
 
 _toggleClass ($element= 'this', $class='')
 
 _show ($element= 'this', $speed= '', $callback= '')
 
 _updater ($container= 'this', $controller, $options= '')
 
 _zebraTables ($class= '', $odd= 'odd', $hover= '')
 
 corner ($element= '', $corner_style= '')
 
 modal ($src, $relative=FALSE)
 
 effect ($src, $relative=FALSE)
 
 plugin ($src, $relative=FALSE)
 
 ui ($src, $relative=FALSE)
 
 sortable ($element, $options=array())
 
 tablesorter ($table= '', $options= '')
 
 _add_event ($element, $js, $event)
 
 _compile ($view_var= 'script_foot', $script_tags=TRUE)
 
 _clear_compile ()
 
 _document_ready ($js)
 
 script ($library_src= '', $relative=FALSE)
 
 _prep_element ($element)
 
 _validate_speed ($speed)
 
- Public Member Functions inherited from CI_Javascript
 __construct ($params=array())
 
 blur ($element= 'this', $js= '')
 
 change ($element= 'this', $js= '')
 
 click ($element= 'this', $js= '', $ret_false=TRUE)
 
 dblclick ($element= 'this', $js= '')
 
 error ($element= 'this', $js= '')
 
 focus ($element= 'this', $js= '')
 
 hover ($element= 'this', $over, $out)
 
 keydown ($element= 'this', $js= '')
 
 keyup ($element= 'this', $js= '')
 
 load ($element= 'this', $js= '')
 
 mousedown ($element= 'this', $js= '')
 
 mouseout ($element= 'this', $js= '')
 
 mouseover ($element= 'this', $js= '')
 
 mouseup ($element= 'this', $js= '')
 
 output ($js)
 
 ready ($js)
 
 resize ($element= 'this', $js= '')
 
 scroll ($element= 'this', $js= '')
 
 unload ($element= 'this', $js= '')
 
 addClass ($element= 'this', $class= '')
 
 animate ($element= 'this', $params=array(), $speed= '', $extra= '')
 
 fadeIn ($element= 'this', $speed= '', $callback= '')
 
 fadeOut ($element= 'this', $speed= '', $callback= '')
 
 slideUp ($element= 'this', $speed= '', $callback= '')
 
 removeClass ($element= 'this', $class= '')
 
 slideDown ($element= 'this', $speed= '', $callback= '')
 
 slideToggle ($element= 'this', $speed= '', $callback= '')
 
 hide ($element= 'this', $speed= '', $callback= '')
 
 toggle ($element= 'this')
 
 toggleClass ($element= 'this', $class='')
 
 show ($element= 'this', $speed= '', $callback= '')
 
 compile ($view_var= 'script_foot', $script_tags=TRUE)
 
 clear_compile ()
 
 external ($external_file= '', $relative=FALSE)
 
 inline ($script, $cdata=TRUE)
 
 _open_script ($src= '')
 
 _close_script ($extra="\n")
 
 update ($element= 'this', $speed= '', $callback= '')
 
 generate_json ($result=NULL, $match_array_type=FALSE)
 
 _is_associative_array ($arr)
 
 _prep_args ($result, $is_key=FALSE)
 

Data Fields

 $_javascript_folder = 'js'
 
 $jquery_code_for_load = array()
 
 $jquery_code_for_compile = array()
 
 $jquery_corner_active = FALSE
 
 $jquery_table_sorter_active = FALSE
 
 $jquery_table_sorter_pager_active = FALSE
 
 $jquery_ajax_img = ''
 
- Data Fields inherited from CI_Javascript
 $_javascript_location = 'js'
 

Member Function Documentation

_add_event (   $element,
  $js,
  $event 
)

Add Event

Constructs the syntax for an event, and adds to into the array for compilation

private

Parameters
stringThe element to attach the event to
stringThe code to execute
stringThe event to pass
Returns
string
_addClass (   $element = 'this',
  $class = '' 
)

Add Class

Outputs a jQuery addClass event

private

Parameters
string- element
Returns
string
_animate (   $element = 'this',
  $params = array(),
  $speed = '',
  $extra = '' 
)

Animate

Outputs a jQuery animate event

private

Parameters
string- element
string- One of 'slow', 'normal', 'fast', or time in milliseconds
string- Javascript callback function
Returns
string
_blur (   $element = 'this',
  $js = '' 
)

Blur

Outputs a jQuery blur event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_change (   $element = 'this',
  $js = '' 
)

Change

Outputs a jQuery change event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_clear_compile ( )

Clear Compile

Clears the array of script events collected for output

public

Returns
void
_click (   $element = 'this',
  $js = '',
  $ret_false = TRUE 
)

Click

Outputs a jQuery click event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
booleanwhether or not to return false
Returns
string
_compile (   $view_var = 'script_foot',
  $script_tags = TRUE 
)

Compile

As events are specified, they are stored in an array This funciton compiles them all for output on a page

private

Returns
string
_dblclick (   $element = 'this',
  $js = '' 
)

Double Click

Outputs a jQuery dblclick event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_document_ready (   $js)

Document Ready

A wrapper for writing document.ready()

private

Returns
string
_error (   $element = 'this',
  $js = '' 
)

Error

Outputs a jQuery error event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_fadeIn (   $element = 'this',
  $speed = '',
  $callback = '' 
)

Fade In

Outputs a jQuery hide event

private

Parameters
string- element
string- One of 'slow', 'normal', 'fast', or time in milliseconds
string- Javascript callback function
Returns
string
_fadeOut (   $element = 'this',
  $speed = '',
  $callback = '' 
)

Fade Out

Outputs a jQuery hide event

private

Parameters
string- element
string- One of 'slow', 'normal', 'fast', or time in milliseconds
string- Javascript callback function
Returns
string
_focus (   $element = 'this',
  $js = '' 
)

Focus

Outputs a jQuery focus event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_hide (   $element = 'this',
  $speed = '',
  $callback = '' 
)

Hide

Outputs a jQuery hide action

private

Parameters
string- element
string- One of 'slow', 'normal', 'fast', or time in milliseconds
string- Javascript callback function
Returns
string
_hover (   $element = 'this',
  $over,
  $out 
)

Hover

Outputs a jQuery hover event

private

Parameters
string- element
string- Javascript code for mouse over
string- Javascript code for mouse out
Returns
string
_keydown (   $element = 'this',
  $js = '' 
)

Keydown

Outputs a jQuery keydown event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_keyup (   $element = 'this',
  $js = '' 
)

Keyup

Outputs a jQuery keydown event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_load (   $element = 'this',
  $js = '' 
)

Load

Outputs a jQuery load event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_mousedown (   $element = 'this',
  $js = '' 
)

Mousedown

Outputs a jQuery mousedown event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_mouseout (   $element = 'this',
  $js = '' 
)

Mouse Out

Outputs a jQuery mouseout event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_mouseover (   $element = 'this',
  $js = '' 
)

Mouse Over

Outputs a jQuery mouseover event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_mouseup (   $element = 'this',
  $js = '' 
)

Mouseup

Outputs a jQuery mouseup event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_output (   $array_js = '')

Output

Outputs script directly

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_prep_element (   $element)

Prep Element

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

public

Parameters
string
Returns
string
_removeClass (   $element = 'this',
  $class = '' 
)

Remove Class

Outputs a jQuery remove class event

private

Parameters
string- element
Returns
string
_resize (   $element = 'this',
  $js = '' 
)

Resize

Outputs a jQuery resize event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_scroll (   $element = 'this',
  $js = '' 
)

Scroll

Outputs a jQuery scroll event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_show (   $element = 'this',
  $speed = '',
  $callback = '' 
)

Show

Outputs a jQuery show event

private

Parameters
string- element
string- One of 'slow', 'normal', 'fast', or time in milliseconds
string- Javascript callback function
Returns
string
_slideDown (   $element = 'this',
  $speed = '',
  $callback = '' 
)

Slide Down

Outputs a jQuery slideDown event

private

Parameters
string- element
string- One of 'slow', 'normal', 'fast', or time in milliseconds
string- Javascript callback function
Returns
string
_slideToggle (   $element = 'this',
  $speed = '',
  $callback = '' 
)

Slide Toggle

Outputs a jQuery slideToggle event

public

Parameters
string- element
string- One of 'slow', 'normal', 'fast', or time in milliseconds
string- Javascript callback function
Returns
string
_slideUp (   $element = 'this',
  $speed = '',
  $callback = '' 
)

Slide Up

Outputs a jQuery slideUp event

private

Parameters
string- element
string- One of 'slow', 'normal', 'fast', or time in milliseconds
string- Javascript callback function
Returns
string
_toggle (   $element = 'this')

Toggle

Outputs a jQuery toggle event

private

Parameters
string- element
Returns
string
_toggleClass (   $element = 'this',
  $class = '' 
)

Toggle Class

Outputs a jQuery toggle class event

private

Parameters
string- element
Returns
string
_unload (   $element = 'this',
  $js = '' 
)

Unload

Outputs a jQuery unload event

private

Parameters
stringThe element to attach the event to
stringThe code to execute
Returns
string
_updater (   $container = 'this',
  $controller,
  $options = '' 
)

Updater

An Ajax call that populates the designated DOM node with returned content

private

Parameters
stringThe element to attach the event to
stringthe controller to run the call against
stringoptional parameters
Returns
string
_validate_speed (   $speed)

Validate Speed

Ensures the speed parameter is valid for jQuery

private

Parameters
string
Returns
string
_zebraTables (   $class = '',
  $odd = 'odd',
  $hover = '' 
)

Zebra tables

private

Parameters
stringtable name
stringplugin location
Returns
string
corner (   $element = '',
  $corner_style = '' 
)

Corner Plugin

http://www.malsup.com/jquery/corner/

public

Parameters
stringtarget
Returns
string
effect (   $src,
  $relative = FALSE 
)

Effect

Load an Effect library

public

Returns
void
modal (   $src,
  $relative = FALSE 
)

modal window

Load a thickbox modal window

public

Returns
void
plugin (   $src,
  $relative = FALSE 
)

Plugin

Load a plugin library

public

Returns
void
script (   $library_src = '',
  $relative = FALSE 
)

Script Tag

Outputs the script tag that loads the jquery.js file into an HTML document

public

Parameters
string
Returns
string
sortable (   $element,
  $options = array() 
)

Sortable

Creates a jQuery sortable

public

Returns
void
tablesorter (   $table = '',
  $options = '' 
)

Table Sorter Plugin

public

Parameters
stringtable name
stringplugin location
Returns
string
ui (   $src,
  $relative = FALSE 
)

UI

Load a user interface library

public

Returns
void

The documentation for this class was generated from the following file: