Jatinder Singh
2008-Apr-23 09:22 UTC
Upload a file using Net:HTTP multipart post or ActiveResource
Hi Guys, I am trying to upload a file to a rails server using a ruby script. http://pastie.org/185380 I verified the parameters of the Net:HTTP post request and they seem to be right. However the recipient, mongre,l shows following message in console and the parameters sent, the file data, is all corrupted. oh and one very weird thing happened. the console running mongrel looks like following after it recieved the file upload request. Earlier I was using ActiveResource to upload a file, but then I realized that it doesn''t have support for multipart content type requests. Thanks Jatinder --~--~---------~--~----~------------~-------~--~----~ 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---