[ Index ]

PHP Cross Reference of Drupal 6 (gatewave)

title

Body

[close]

/sites/all/modules/ctools/includes/ -> ajax.inc (summary)

(no description)

File Size: 681 lines (22 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 27 functions

  ctools_ajax_image_button()
  ctools_ajax_text_button()
  ctools_ajax_command_error()
  ctools_ajax_command_replace()
  ctools_ajax_command_html()
  ctools_ajax_command_prepend()
  ctools_ajax_command_append()
  ctools_ajax_command_after()
  ctools_ajax_command_before()
  ctools_ajax_command_remove()
  ctools_ajax_command_changed()
  ctools_ajax_command_css()
  ctools_ajax_command_css_files()
  ctools_ajax_command_settings()
  ctools_ajax_command_scripts()
  ctools_ajax_command_data()
  ctools_ajax_command_attr()
  ctools_ajax_command_restripe()
  ctools_ajax_command_redirect()
  ctools_ajax_command_reload()
  ctools_ajax_command_submit()
  ctools_ajax_render()
  ctools_ajax_render_error()
  ctools_ajax_associate_url_to_element()
  ctools_ajax_page_preprocess()
  ctools_process_js_files()
  ctools_process_css_files()

Functions
Functions that are not part of a class:

ctools_ajax_image_button($image, $dest, $alt, $class = '')   X-Ref
Render an image as a button link. This will automatically apply an AJAX class
to the link and add the appropriate javascript to make this happen.

param: $image
param: $dest
param: $alt
param: $class

ctools_ajax_text_button($text, $dest, $alt, $class = '', $type = 'ctools-use-ajax')   X-Ref
Render text as a link. This will automatically apply an AJAX class
to the link and add the appropriate javascript to make this happen.

Note: 'html' => true so be sure any text is vetted! Chances are these kinds of buttons will
not use user input so this is a very minor concern.

param: $image
param: $dest
param: $alt
param: $class
param: $type

ctools_ajax_command_error($error = '')   X-Ref
Create a command array for the error case.


ctools_ajax_command_replace($selector, $html)   X-Ref
Create a replace command for the AJAX responder.

The replace command will replace a portion of the current document
with the specified HTML.

param: $selector
param: $html

ctools_ajax_command_html($selector, $html)   X-Ref
Set the HTML of a given selector to the given data.

param: $selector
param: $html

ctools_ajax_command_prepend($selector, $html)   X-Ref
Create a prepend command for the AJAX responder.

This will prepend the HTML to the specified selector.

param: $selector
param: $html

ctools_ajax_command_append($selector, $html)   X-Ref
Create an append command for the AJAX responder.

This will append the HTML to the specified selector.

param: $selector
param: $html

ctools_ajax_command_after($selector, $html)   X-Ref
Create an after command for the AJAX responder.

This will add the HTML after the specified selector.

param: $selector
param: $html

ctools_ajax_command_before($selector, $html)   X-Ref
Create a before command for the AJAX responder.

This will add the HTML before the specified selector.

param: $selector
param: $html

ctools_ajax_command_remove($selector)   X-Ref
Create a remove command for the AJAX responder.

This will remove the specified selector and everything within it.

param: $selector

ctools_ajax_command_changed($selector, $star = '')   X-Ref
Create a changed command for the AJAX responder.

This will mark an item as 'changed'.

param: $selector
param: $star

ctools_ajax_command_css($selector, $argument)   X-Ref
Create a css command for the AJAX responder.

This will directly add CSS to the page.

param: $selector
param: $argument

ctools_ajax_command_css_files($argument)   X-Ref
Create a settings command for the AJAX responder.

This will add CSS files to the output. Files that have already
been processed will not be processed again.

param: $argument

ctools_ajax_command_settings($argument)   X-Ref
Create a settings command for the AJAX responder.

This will extend Drupal.settings with the given array.

param: $argument

ctools_ajax_command_scripts($argument)   X-Ref
Create a settings command for the AJAX responder.

This will add javascript files to the output. Files that have already
been processed will not be processed again.

param: $argument

ctools_ajax_command_data($selector, $name, $value)   X-Ref
Create a data command for the AJAX responder.

This will attach the name=value pair of data to the selector via
jquery's data cache.

param: $selector
param: $name
param: $value

ctools_ajax_command_attr($selector, $name, $value)   X-Ref
Set a single property to a value, on all matched elements.

param: $selector
param: $name
param: $value

ctools_ajax_command_restripe($selector)   X-Ref
Force a table to be restriped.

This is usually used after a table has been modifed by a replace or append
command.

param: $selector

ctools_ajax_command_redirect($url, $delay = 0, $options = array()   X-Ref
Force a client-side redirect.

param: $url
param: $delay
param: $options

ctools_ajax_command_reload()   X-Ref
Force a reload of the current page.


ctools_ajax_command_submit($selector)   X-Ref
Submit a form.

This is useful for submitting a parent form after a child form has finished
processing in a modal overlay.

param: $selector

ctools_ajax_render($commands = array()   X-Ref
Render a commands array into JSON and immediately hand this back
to the AJAX requester.


ctools_ajax_render_error($error = '')   X-Ref
Send an error response back via AJAX and immediately exit.


ctools_ajax_associate_url_to_element(&$form, &$form_element, $dest, $type = '')   X-Ref
Associate a URL to a form element with a hidden form.

This is a helper function to easily associate a URL with a form element
which can be used for different ajax functionality.

You would call this function on a form element in the form function like this:

param: &$form
param: &$form_element
param: $dest
param: $type

ctools_ajax_page_preprocess(&$variables)   X-Ref
No description

ctools_process_js_files(&$js_files, $scope)   X-Ref
Create a list of javascript files that are on the page.


ctools_process_css_files(&$css_files, $css)   X-Ref
Create a list of CSS files to add to the page.




Generated: Thu Mar 24 11:18:33 2011 Cross-referenced by PHPXref 0.7