Screen Scraping from a web page with a lot of Javascript [closed]

You may consider using HTMLunit
It’s a java class library made to automate browsing without having to control a browser, and it integrates the Mozilla Rhino Javascript engine to process javascript on the pages it loads. There’s also a JRuby wrapper for that, named Celerity. Its javascript support is not really perfect right now, but if your pages don’t use many hacks things should work fine the performance should be way better than controlling a browser. Furthermore, you don’t have to worry about cookies being persisted after your scraping is over and all the other nasty things connected to controlling a browser (history, autocomplete, temp files etc).

Leave a Comment