Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
ruby https post
Cristian Prodan
9/25/2008 1:56:00 PM
Hello,
I'm trying to make a post request to a server. This is the code I use:
---
require 'net/http'
require 'uri'
res = Net::HTTP.post_form(URI.parse('https://someValidURL'),
{:trans_id => "123456", :amount => "20.00"})
puts res.body
---
I get back this error:
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/net/protocol.rb:133:in
`sysread': end of file reached (EOFError)
I searched the web but didn't find an answer. Can anyone please help ?
Thanks in advance.
--
Posted via
http://www.ruby-...
.
1 Answer
Lex Williams
9/25/2008 2:46:00 PM
0
Check mechanize at
http://mechanize.rubyforge.org/...
. Read the
"Filling forms" section.
--
Posted via
http://www.ruby-...
.
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
ruby https post
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password