Posting Forms

Posting forms looks like it should be easy with Ruby 1.8.3 and

Can anyone provide an example of submitting a search to e.g.,
and printing out the results?

This code doesn’t seem to work.

require ‘net/http’
require ‘uri’

#site=‘’ doesn’t work either


res = Net::HTTP.post_form(URI.parse(site),
puts res.body


This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs