public Method

ScriptaculousHelper.drop_receiving_element_js(element_id, options = {})

There's no documentation for this item.

Source Code

# File action_view/helpers/scriptaculous_helper.rb, line 187
def drop_receiving_element_js(element_id, options = {}) #:nodoc:
  options[:with]     ||= "'id=' + encodeURIComponent(element.id)"
  options[:onDrop]   ||= "function(element){" + remote_function(options) + "}"
  options.delete_if { |key, value| PrototypeHelper::AJAX_OPTIONS.include?(key) }

  options[:accept] = array_or_string_for_javascript(options[:accept]) if options[:accept]    
  options[:hoverclass] = "'#{options[:hoverclass]}'" if options[:hoverclass]

  %(Droppables.add(#{element_id.to_json}, #{options_for_javascript(options)});)
end
Comments

Have your say
Please use Textile formatting (click here for a cheat sheet). Use <code/> and <pre/> for code samples.
Click here to login with OpenID to to post comments.