diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2006-05-28 23:39:37 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2006-05-28 23:39:37 +0000 |
commit | 140a998de31ed4547e0d21715165f4b338030673 (patch) | |
tree | 99b1b2d145cfef351ce49d06e9cda1c459ed404a /actionpack/lib/action_view/helpers/prototype_helper.rb | |
parent | d84ba8b8a93330fbd893b809284d3f21c8eb1177 (diff) | |
download | rails-140a998de31ed4547e0d21715165f4b338030673.tar.gz rails-140a998de31ed4547e0d21715165f4b338030673.tar.bz2 rails-140a998de31ed4547e0d21715165f4b338030673.zip |
Added :method handling for other verbs to remote_form_tag and remote_form_for [DHH]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4374 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib/action_view/helpers/prototype_helper.rb')
-rw-r--r-- | actionpack/lib/action_view/helpers/prototype_helper.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/actionpack/lib/action_view/helpers/prototype_helper.rb b/actionpack/lib/action_view/helpers/prototype_helper.rb index 3c4c0ba98d..bf32dd9f49 100644 --- a/actionpack/lib/action_view/helpers/prototype_helper.rb +++ b/actionpack/lib/action_view/helpers/prototype_helper.rb @@ -164,10 +164,8 @@ module ActionView options[:html] ||= {} options[:html][:onsubmit] = "#{remote_function(options)}; return false;" - options[:html][:action] = options[:html][:action] || url_for(options[:url]) - options[:html][:method] = options[:html][:method] || "post" - tag("form", options[:html], true) + form_tag(options[:html].delete(:action) || url_for(options[:url]), options[:html]) end # Works like form_remote_tag, but uses form_for semantics. |