Project

General

Profile

Bug #969 » cr.rb

ender672 (Timothy Elliott), 01/02/2009 07:41 PM

 
require 'URI'
require 'net/http'

body_string = 'a' * 23500
url = 'http://google.com'

uri = URI.parse url
http = Net::HTTP.new uri.host, uri.port
req = Net::HTTP::Post.new uri.request_uri
req.body = body_string
response = http.start{|conn| conn.request req}
puts response.body
(1-1/2)