>>653
open-uri を使って URI#open した返り値の文字列なら標準で使える
OpenURI::Meta で拡張されています云々というアレ
open(uri).read と書くとこの芸はできないので注意

require 'open-uri'
uri = URI.parse('http://pc11.2ch.net/test/read.cgi/tech/1203658291/l50')
html = uri.read({'User-Agent'=>'Monazilla/1.00'})

p html.base_uri.to_s
p html.last_modified
p html.meta
html.meta_add_field('Title','Ruby 初心者スレッド Part 18')
puts html.meta['title']


# 結果
"http://pc11.2ch.net/test/read.cgi/tech/1203658291/l50"
nil
{"vary"=>"Accept-Encoding", "connection"=>"close", "content-type"=>"text/html",
"date"=>"Mon, 24 Mar 2008 12:49:07 GMT",
"server"=>"Apache/2.0.59 (Unix) PHP/4.4.2 mod_ssl/2.0.59 OpenSSL/0.9.7e-p1", "transfer-encoding"=>"chunked"}
Ruby 初心者スレッド Part 18