Saturday, 10 June 2017

Cheerio scraping: Not able to find elements in HTML response

I have a HTML response as:

<table id="\&quot;tableone\&quot;" class="\&quot;sortable">

Now ,when I tries to find element with the ID #tableone ,it returns nothing but if I try to find using 'table' it works.

var $ = cheerio.load(html)
console.log('tableone:'+ $('#tableone').length)          => 0



via Jaswinder

No comments:

Post a Comment