F
Francis Hwang
I can't find this answered in the RDoc, so I'll ask here: How do I send
the cookie string in an HTTP request using Net::HTTP? I tried doing
something like:
Net::HTTP.start( 'server.host.here' ) { |http|
response = http.get(
'/local/file.rb',
'Cookie: cookie_name=cookie_val'
)
}
hoping that the "initheader" in HTTP#get is where I should drop the
cookie value, but that just gave me a traceback.
Francis Hwang
http://fhwang.net/
the cookie string in an HTTP request using Net::HTTP? I tried doing
something like:
Net::HTTP.start( 'server.host.here' ) { |http|
response = http.get(
'/local/file.rb',
'Cookie: cookie_name=cookie_val'
)
}
hoping that the "initheader" in HTTP#get is where I should drop the
cookie value, but that just gave me a traceback.
Francis Hwang
http://fhwang.net/