From: Pit Capitain Date: 2003-05-10T15:40:01+09:00 Subject: Re: Is there a tutorial on parsing text? On 10 May 2003 at 12:29, Mark Wilson wrote: > > On Friday, May 9, 2003, at 09:23 PM, Robo wrote: > > > [snip] > > > How to send HTTP POST > > using Ruby, how to get the HTML pages back, how to extract the TV > > programs > > out of those HTML pages. > > > > [snip] > > I don't know of a tutorial on parsing text in Ruby. > > For getting pages, you might look at how webfetcher does it: > > http://www.acc.umu.se/~r2d2/programming/ruby/webfetcher/ > > curl, a unix program, can handle pages where the site must set a cookie > before it gives you access to a page. See: > > http://curl.haxx.se/ > > For text parsing after you get the pages, see the relevant sections of > the pick-ax book (strings and regular expressions). The book can be > found here: > > http://www.rubycentral.com/book/index.html There's also at least one HTML parsing library in the RAA. I haven't used it, so I can't tell you more details. Regards, Pit