Live data from Hacker News

Ask HN: Does anyone have experience scraping dynamic content?

news.ycombinator.com

1–5 of 5 posts

Ask HN: Does anyone have experience scraping dynamic content?

#1
http://www.nfl.com/scores

For example, for this URL, there is a section on the right for "Big Play Highlights" and the first one listed is "L.Brown 7-yard TD pass from..."

It looks like this data is being loaded via some kind of AJAX call. Do you have any ideas on how I can scrape this stream of highlights data? I've never tried to scrape any dynamic content in the past.

Ideas?

Re: Ask HN: Does anyone have experience scraping dynamic content?

#2
You MAY be able to do this with Selenium, although I've never used Selenium to scrape streaming requests. It's going to depend quite a bit on how the page is structured.

I have used Selenium to scrape dynamic content before by waiting for new DOM elements to be populated by AJAX, so I know this sort of thing is possible in a way you couldn't do with wget.