diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-04-17 15:29:37 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-04-17 15:29:37 -0300 |
commit | cbb917455f306cf5818644b162f22be09f77d4b2 (patch) | |
tree | 60500a2db1f865523b5824d54decce811dfc17ae /actionview/lib | |
parent | c91a531ff384f70f72e7e0e213424d3e42a48c27 (diff) | |
parent | 89ff1f82f01bd70e12ec1b45049be30ac262df30 (diff) | |
download | rails-cbb917455f306cf5818644b162f22be09f77d4b2.tar.gz rails-cbb917455f306cf5818644b162f22be09f77d4b2.tar.bz2 rails-cbb917455f306cf5818644b162f22be09f77d4b2.zip |
Merge pull request #14738 from tilsammans/pull/11407
Remove wrapping div with inline styles for hidden form fields.
Conflicts:
actionview/CHANGELOG.md
Diffstat (limited to 'actionview/lib')
-rw-r--r-- | actionview/lib/action_view/helpers/form_tag_helper.rb | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/actionview/lib/action_view/helpers/form_tag_helper.rb b/actionview/lib/action_view/helpers/form_tag_helper.rb index b4a841b946..66c9e20682 100644 --- a/actionview/lib/action_view/helpers/form_tag_helper.rb +++ b/actionview/lib/action_view/helpers/form_tag_helper.rb @@ -778,9 +778,11 @@ module ActionView method_tag(method) + token_tag(authenticity_token) end - enforce_utf8 = html_options.delete("enforce_utf8") { true } - tags = (enforce_utf8 ? utf8_enforcer_tag : ''.html_safe) << method_tag - content_tag(:div, tags, :style => 'display:none') + if html_options.delete("enforce_utf8") { true } + utf8_enforcer_tag + method_tag + else + method_tag + end end def form_tag_html(html_options) |