From: Zach Dennis Date: 2005-10-27T02:40:56+09:00 Subject: Re: Getting IP addresses Joel Watson wrote: > require 'open-uri' > > page = URI.parse("http://www.whatismyip.com") > > html = page.read > > ip = html.scan(/.*?([0-9]{1,3}[.][0-9]{1,3}[.][0-9]{1,3}[.][0-9] > {1,3}).*/).flatten.first > Beautiful! To go with what Joel did... ip = html.scan( /(([0-9]{1,3}\.?){4})/ ).flatten.first Zach