aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_view/helpers/javascript_helper.rb
diff options
context:
space:
mode:
authorJamis Buck <jamis@37signals.com>2005-09-02 13:56:38 +0000
committerJamis Buck <jamis@37signals.com>2005-09-02 13:56:38 +0000
commit97adfdaa6597953a4c4f501ce340c27caf85c069 (patch)
tree12074c59ad51eaf11803094a14e7eb194e522da1 /actionpack/lib/action_view/helpers/javascript_helper.rb
parente3d34286e338bdd6c7681e08a0d79a955dc24ca1 (diff)
downloadrails-97adfdaa6597953a4c4f501ce340c27caf85c069.tar.gz
rails-97adfdaa6597953a4c4f501ce340c27caf85c069.tar.bz2
rails-97adfdaa6597953a4c4f501ce340c27caf85c069.zip
* Allow use of the :with option for submit_to_remote #1936 [jon@instance-design.co.uk]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2103 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib/action_view/helpers/javascript_helper.rb')
-rw-r--r--actionpack/lib/action_view/helpers/javascript_helper.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_view/helpers/javascript_helper.rb b/actionpack/lib/action_view/helpers/javascript_helper.rb
index 76be539332..2bd741bd79 100644
--- a/actionpack/lib/action_view/helpers/javascript_helper.rb
+++ b/actionpack/lib/action_view/helpers/javascript_helper.rb
@@ -153,7 +153,7 @@ module ActionView
# Returns a button input tag that will submit form using XMLHttpRequest in the background instead of regular
# reloading POST arrangement. <tt>options</tt> argument is the same as in <tt>form_remote_tag</tt>
def submit_to_remote(name, value, options = {})
- options[:with] = 'Form.serialize(this.form)'
+ options[:with] ||= 'Form.serialize(this.form)'
options[:html] ||= {}
options[:html][:type] = 'button'