Mega Code Archive
Categories
/
Ruby
/
Network
Extracting All the URLs from an HTML Document
require 'uri' text = %{"test
http://www.example.com/
, and be sure to check out my weblog at http://www.example.com/blog/. Email me at
b@e.com
.} p URI.extract(text)