From: Derek Cannon on 19 Apr 2010 03:32 Hey! This is the first question I can contribute too! I found a very useful tool for finding out what tags you can use to parse information in Nokogiri. It's called SelectorGadget. Check it out at http://www.selectorgadget.com/ Watch the tutorial video and I think you'll be very pleased with the results. --Derek -- Posted via http://www.ruby-forum.com/.
From: Derek Cannon on 19 Apr 2010 03:38 Also, how you would enter this information into Ruby using Nokogiri after letting SelectorGadget find the CSS path you want is: require 'nokogiri' require 'open-uri' doc = Nokogiri::HTML(open(YOUR_URL_HERE)) doc.css("YOUR SelectGadget PATH HERE").each { |i| # do something } -- Posted via http://www.ruby-forum.com/.
From: Andrea Dallera on 19 Apr 2010 03:42 Hei Derek, thanks a lot for the suggestion! I use mechanize a lot and this tool will be very useful: getting the right query is very tricky sometimes, this makes it a no brainer. -- Andrea Dallera http://github.com/bolthar/freightrain http://usingimho.wordpress.com On Mon, 2010-04-19 at 16:32 +0900, Derek Cannon wrote: > Hey! This is the first question I can contribute too! I found a very > useful tool for finding out what tags you can use to parse information > in Nokogiri. It's called SelectorGadget. > > Check it out at http://www.selectorgadget.com/ > > Watch the tutorial video and I think you'll be very pleased with the > results. > > --Derek
|
Pages: 1 Prev: Life without Method Overloading? Next: [ANN] rdoc-rake 1.0 Released |