extracting where there is id, not class

17 views
Skip to first unread message

Ben Edwards

unread,
Aug 7, 2017, 8:02:59 PM8/7/17
to nokogiri-talk
I am writing a scraper for a site that does ont use classes mutch, it used a lot of div tags with ids, i.e.

<div id="main">

Is there a way to use these

the other thing that it looks like they are forgeting to close tags so almost everything is nested inside the other.  There is a news class but eatch item is nested inside the last, alough they should not be.

Ben

Ben Edwards

unread,
Aug 8, 2017, 3:59:29 PM8/8/17
to nokogiri-talk
worked it out

html.at_css("div#verify")

where verify is an id


Reply all
Reply to author
Forward
0 new messages