From: Enrique Comba Riepenhausen Date: 2007-05-26T06:16:11+09:00 Subject: Re: Net::HTTP - POST and GET in the same request > The x=y become POST variables and the {'A'=>'1' ...} drop out of the > equation entirely. > > Actual code: > > http = Net:HTTP.new(domain.com) > response = http.post(script.asp,'x=y',{'A'=>'1','B'=>'2'}) > content = response.body > > Perhaps I have misapplied it? > > Note: including http:// in the domain gives a connection error, > strangely. That is true, my typo... OOOOPsssss I'm sorry, my fault! Try this: http = Net::HTTP.new('domain.com') response = http.post('/script.asp', 'x=y') content = response.body The {} sets header fields if you take a closer look at the post request itself you will see them there. Cheers, ---- Enrique Comba Riepenhausen ecomba@mac.com I always thought Smalltalk would beat Java, I just didn't know it would be called 'Ruby' when it did. -- Kent Beck