Created
June 11, 2009 14:50
-
-
Save dmichael/127944 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # From the OpenURI documentation | |
| open("http://www.ruby-lang.org/en") {|f| | |
| f.each_line {|line| p line} | |
| p f.base_uri # <URI::HTTP:0x40e6ef2 URL:http://www.ruby-lang.org/en/> | |
| p f.content_type # "text/html" | |
| p f.charset # "iso-8859-1" | |
| p f.content_encoding # [] | |
| p f.last_modified # Thu Dec 05 02:45:02 UTC 2002 | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment