Post Data From Ruby


/ Published in: Ruby
Save to your folder(s)



Copy this code and paste it in your HTML
  1. uri = URI.parse(url)
  2. req = Net::HTTP::Post.new(url)
  3. req.set_form_data({
  4. \'field\' => \'value\'
  5. })
  6. res = Net::HTTP.new(uri.host, uri.port).start { |http| http.request(req) }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.