private Method

FormTagHelper.extra_tags_for_form(html_options)

There's no documentation for this item.

Source Code

# File action_view/helpers/form_tag_helper.rb, line 415
def extra_tags_for_form(html_options)
  case method = html_options.delete("method").to_s
    when /^get$/i # must be case-insentive, but can't use downcase as might be nil
      html_options["method"] = "get"
      ''
    when /^post$/i, "", nil
      html_options["method"] = "post"
      protect_against_forgery? ? content_tag(:div, token_tag, :style => 'margin:0;padding:0') : ''
    else
      html_options["method"] = "post"
      content_tag(:div, tag(:input, :type => "hidden", :name => "_method", :value => method) + token_tag, :style => 'margin:0;padding:0')
  end
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.