From: Max Williams Date: 2008-07-12T01:05:25+09:00 Subject: Regex to find urls in text? On our site, our resources have a description, which is often copied and pasted from somewhere else. Often these descriptions have urls in them, just as normal text, and i'd like to automatically make these into working links. I was thinking of using gsub as below: def description_with_links regex = ???? self.description.gsub(regex) {|url|"#{url}"} end The above should work ok, once i have the regex but i can't work it out. Can anyone help? thanks max -- Posted via http://www.ruby-forum.com/.