This project is archived and is in readonly mode.
Rails escapes quotes at when they are at beginning and and of signle-line string
-
Ryan Bigg
- Tag changed from escaping, quotes, textarea to bugmash, escaping, quotes, textarea
- State changed from new to incomplete
Please provide a failing test case and patch for this issue.
-
Rohit Arondekar
The same problem happens with text_field also.
-
Neeraj Singh
- Tag changed from bugmash, escaping, quotes, textarea to bugmash, escaping, quotes, rails3, textarea
This is not a rails issue.
Rails is exhibiting this behavior because rack is doing all the work of converting user input in params. Take a look at this test case in rack. http://github.com/rack/rack/blob/master/test/spec_rack_utils.rb#L35 . rack is coded to remove the double quotes which the author of ticket does not want.
If you add a new line character then double quotes is preserved. http://github.com/neerajdotname/rack/commit/1454a2171032e2260dc7199...
I have posted a question on the rack mailing list about this issue. When a resolution comes I will update this issue.
-
Ryan Bigg
- Tag changed from bugmash, escaping, quotes, rails3, textarea to escaping, quotes, rails3, textarea
-
andreas
Dupe: #4808 Textarea input silently truncated in 2.3.8!
Rails still requires the broken rack version, this should be fixed ASAP