# Form handling by rails

**URL:** <https://www.ruby-forum.com/t/form-handling-by-rails/177631>\
**Category:** Rails\
**Created:** [October 21, 2009, 10:17am UTC](https://www.ruby-forum.com/t/form-handling-by-rails/177631 "2009-10-21T10:17:53Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nicholas\_W](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/f17d59/32.png) [@Nicholas\_W](https://www.ruby-forum.com/u/Nicholas_W)\
**Post date:** [October 21, 2009, 10:17am UTC](https://www.ruby-forum.com/t/form-handling-by-rails/177631/1 "2009-10-21T10:17:53Z")

</div>

Hi guys, I’m writing a sinatra app that interfaces to a Rails core,  
authenticating with OAuth and making requests to the main service.  
I’m experiencing a weird behaviour and I hope that someone can give me  
a clue about what’s happening here.  
By inspecting request and response I noticed something very weird.  
Sorry if this is long.

This is my request from Sinatra to Rails (only the query hash):

“rack.request.query\_hash”=\>{“contest”=\>{“it”=\>{“brief”=\>“

Vi  
lanciamo un contest originale, che avr\303\240 sviluppi professionali  
interessanti per chi ne risulter\303\240 vincitore. (…)”}}}

This is how Rails handles it:

Parameters: {“it”=\>“brief

Vi lanciamo un contest originale, che avrÃ  
sviluppi professionali interessanti per chi ne risulterÃ vincitore.  
(…)”}

It basically flattens everything in there.  
Maybe I’m mistaken and I’m doing something wrong (as usual), but it  
seems Rails has a problem here handling parameters in the correct way.  
I also posted the same question to the OAuth gem ML, but by looking at  
the code of the gem I don’t see anything strange.

ngw

–  
Nicholas W. (ngw)  
Zooppa CTO  
911 Western Avenue, Suite 420  
Seattle, WA 98104 US
