- See more at: http://blogtimenow.com/blogging/automatically-redirect-blogger-blog-another-blog-website/#sthash.YsVbCxL0.dpuf Journey to Becoming a Web Developer: REXML and Nokogiri

Sunday, December 8, 2013

REXML and Nokogiri

When I started working on the Economics XML challenge I didn't realize that REXML and Nokigiri were both parsers that do the same things, but there are some differences, so I decided to the a post on a few. REXML is a parser that is already built into Ruby while we have to install a gem to use Nokogiri. REXML is also an older and slower parser, so many prefer to use Nokogiri. In REXML in order to access nodes it uses XPath which is a language for selecting nodes from an XML document, the match method, and the attributes method all used to access elements or nodes in an XML or HTML file while in Nokogiri the only method necessary to access elements is search and the tag name. Here is an interesting tutorial I found on scraping with Nokogiri


No comments:

Post a Comment