In jq4r version 0.1, the following helpers are provided:
jq_link_to_remote
This method works as the originallink_to_remote
method. It creates a link tag but overrides the click event handler to send request to a remote action. The relationship betweenjq_link_to_remote
andlink_to_remote
is thatjq_link_to_remote
is a jQuery-based implementation oflink_to_remote
jq_load_from_remote
This method also creates a link to a remote action but update the content (innerHTML) of a element by the response of a remote action. It's a simplified version ofjq_link_to_remote
, because it simply generates$(elem).load()
script instead of$.ajax(...)
.jq_form_remote_tag
As the originalform_remote_tag
, it creates theform
tag and overrides the submit event handler.jq_form_remote_tag
is the jQuery-based implementation ofform_remote_tag
.jq_remote_form_for
Asjq_form_remote_tag
, this method is another way to create theform
tag with AJAX actions.jq_submit_to_remote
Creates a button tag (accurately, aninput
tag) thats submit data to a remote action. If the data are not specified, it will submit whole fields' values within aform
.jq_periodically_call_remote
Requests a remote action periodically. With:frequency
option you man specify how long is the request be fired.jq_observe_field
Observes a field within a form. While the timer event comes (if you specify the:frequency
option) or there's something changed within the field, the callback function will be executed.jq_observe_form
Asjq_observe_form
, it observes a form, instead.jq_visual_effect
By callingjq_visual_effect
, you can make animations in the page. As the originalvisual_effect
, the first parameter is the effect's name. In jq4r version 0.1, you may use:animate
,:slide_up / :slide_down
, and:fade_in / :fade_out / :fade_to
.
No comments:
Post a Comment