自己想尝试下抓取页面数据
想拿到的数据应该是
这一排文字
然
后自己用代码根据class拿到了
我的代码是
最后想过滤 信息 不太清楚 请教各位师哥
这是我自己的代码
public class ceshi {
public static void main(String[] args) throws IOException {
zhuaqu();
}
private static void zhuaqu() throws IOException {
// String url="http://www.buildhr.com/area/";
String url="https://www.huya.com/";
Document document = Jsoup.parse(new URL(url), 30000);
/*拿到class信息*/
Elements elementsByClass = document.getElementsByClass("huya-footer_friend");
System.out.println("拿到class所有信息"+elementsByClass);
}
}