Flowdock
method

visual_effect

Importance_2
Ruby on Rails latest stable (v4.1.8) - 0 notes - Class: ActionView::Helpers::ScriptaculousHelper

Method deprecated or moved

This method is deprecated or moved on the latest stable version. The last existing version (v3.0.9) is shown here.

visual_effect(name, element_id = false, js_options = {}) public

Returns a JavaScript snippet to be used on the Ajax callbacks for starting visual effects.

If no element_id is given, it assumes “element” which should be a local variable in the generated JavaScript execution context. This can be used for example with drop_receiving_element:

<%= drop_receiving_element (...), :loading => visual_effect(:fade) %>

This would fade the element that was dropped on the drop receiving element.

For toggling visual effects, you can use :toggle_appear, :toggle_slide, and :toggle_blind which will alternate between appear/fade, slidedown/slideup, and blinddown/blindup respectively.

You can change the behaviour with various options, see http://script.aculo.us for more documentation.

Show source
Register or log in to add new notes.