400401402403404405406407408409410
/** * 获取视频地址 */ Element flashEt = doc.getElementById("video-share-code"); doc = Jsoup.parse(flashEt.attr("value")); String flash = doc.select("embed").attr("src"); Video video = new Video(); video.setTitle(title); video.setThumbnail(pic);
678679680681682683684685686687688
* 属于名 * @return 返回属性值 */ private static String getElementAttrById(Document doc, String id, String attrName) throws Exception { Element et = doc.getElementById(id); String attrValue = et.attr(attrName); return attrValue; } /** * 根据FLASH地址生成页面代码