> I can find the section I want with a regex but I don't know how to
> iterate through the string looking for particular elements.  I was
> thinking about taking the section I'm interested in and saving it as
> an array and then iterating through each array element (html line)
> that way, but I thought there might be a quicker way to do it.

$html.scan(%r{<div.*first section.*</div>}m).to_s.scan(/<li>/).size
-- 
Posted via http://www.ruby-forum.com/.