This project is archived and is in readonly mode.

Changeset [25215d7285db10e2c04d903f251b791342e4dd6a] by wycats

June 28th, 2010 @ 05:13 AM

Fix several known web encoding issues:

  • Specify accept-charset on all forms. All recent browsers, as well as IE5+, will use the encoding specified for form parameters
  • Unfortunately, IE5+ will not look at accept-charset unless at least one character in the form's values is not in the page's charset. Since the user can override the default charset (which Rails sets to UTF-8), we provide a hidden input containing a unicode character, forcing IE to look at the accept-charset.
  • Now that the vast majority of web input is UTF-8, we set the inbound parameters to UTF-8. This will eliminate many cases of incompatible encodings between ASCII-8BIT and UTF-8.
  • You can safely ignore params[:snowman]

TODO:

Committed by wycats

  • M actionpack/lib/action_dispatch/http/parameters.rb
  • M actionpack/lib/action_view/helpers/form_tag_helper.rb
  • M actionpack/test/dispatch/request/url_encoded_params_parsing_test.rb
  • M actionpack/test/template/erb/form_for_test.rb
  • M actionpack/test/template/erb/tag_helper_test.rb
  • M actionpack/test/template/form_helper_test.rb
  • M actionpack/test/template/form_tag_helper_test.rb

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>