Switched to use `display:none` in extra_tags_for_form method. #6608

Closed
wants to merge 1 commit into
from
@@ -55,7 +55,7 @@ module Helpers
# The HTML generated for this would be (modulus formatting):
#
# <form action="/people" class="new_person" id="new_person" method="post">
- # <div style="margin:0;padding:0;display:inline">
+ # <div style="margin:0;padding:0;display:none">
# <input name="authenticity_token" type="hidden" value="NrOp5bsjoLRuK8IW5+dQEYjKGUJDe7TQoZVvq95Wteg=" />
# </div>
# <label for="person_first_name">First name</label>:
@@ -85,7 +85,7 @@ module Helpers
# the code above as is would yield instead:
#
# <form action="/people/256" class="edit_person" id="edit_person_256" method="post">
- # <div style="margin:0;padding:0;display:inline">
+ # <div style="margin:0;padding:0;display:none">
# <input name="_method" type="hidden" value="put" />
# <input name="authenticity_token" type="hidden" value="NrOp5bsjoLRuK8IW5+dQEYjKGUJDe7TQoZVvq95Wteg=" />
# </div>
@@ -323,7 +323,7 @@ def convert_to_model(object)
# The HTML generated for this would be:
#
# <form action='http://www.example.com' method='post' data-remote='true'>
- # <div style='margin:0;padding:0;display:inline'>
+ # <div style='margin:0;padding:0;display:none'>
# <input name='_method' type='hidden' value='put' />
# </div>
# ...
@@ -705,7 +705,7 @@ def extra_tags_for_form(html_options)
end
tags = utf8_enforcer_tag << method_tag
- content_tag(:div, tags, :style => 'margin:0;padding:0;display:inline')
+ content_tag(:div, tags, :style => 'margin:0;padding:0;display:none')
end
def form_tag_html(html_options)
@@ -2654,7 +2654,7 @@ def initialize(object_name, object, template, options, block)
protected
def hidden_fields(method = nil)
- txt = %{<div style="margin:0;padding:0;display:inline">}
+ txt = %{<div style="margin:0;padding:0;display:none">}
txt << %{<input name="utf8" type="hidden" value="&#x2713;" />}
if method && !method.to_s.in?(['get', 'post'])
txt << %{<input name="_method" type="hidden" value="#{method}" />}
@@ -14,7 +14,7 @@ def setup
def hidden_fields(options = {})
method = options[:method]
- txt = %{<div style="margin:0;padding:0;display:inline">}
+ txt = %{<div style="margin:0;padding:0;display:none">}
txt << %{<input name="utf8" type="hidden" value="&#x2713;" />}
if method && !method.to_s.in?(['get','post'])
txt << %{<input name="_method" type="hidden" value="#{method}" />}