I am doing an http get using the url 
http://localhost/add?add_key[0][key]=1234&add_key[0][id]=1.
I have a rails app which gives me a neat params hash
{"add_key"=>{"0"=>{"key"=>"1234", "id"=>"1"}}.

Now I try to post these to another server, using Net::HTTP.post_form
new_url,params

The second server gets a form hash -  {"add_key"=>"0key1234id1"}.
Looks like post_form requires a string:string hash. How do I unpack
the params hash back to the original parameter syntax -  {"add_key[0]
[key]" => "1234", add_key[0][id]" => "1"} ?

I have used CGI.parse which works if the original request is a GET.
But if the parameters are passed in a POST, it doesn't work.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to