Scraping data from website that uses javascript

跟風遠走 提交于 2019-12-11 20:37:56

问题


I'm currently working on a program that checks University class availability but the website uses javascript to display classes and their times. Using Java, I'm working on scraping this data and using it to tell users when classes are open.

I've tried using Selenium but I do not really know how to use it very well. Is there an easier way to do this?


回答1:


Without specific is hard to know. But I assume that if the data is not in the page at load time they may be using AJAX to load it.

As I said I may be assuming too much, but your question is vague, if they use AJAX, check the call they do (and get a json response with a bit of luck) and your work will be extremely easy.



来源:https://stackoverflow.com/questions/16762127/scraping-data-from-website-that-uses-javascript

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!