我想從一個網頁的HTML源代碼中所有圖片的URL列表(無論abosulte和相對URL)。我用Jsoup解析HTML,但沒有給出所有圖像。例如,當我解析google.com HTML源其示出零images..In google.com HTML源圖像鏈接在形式上..提取任何圖片,HTML使用Java
"background:url(/intl/en_com/images/srpr/logo1w.png)
而在rediff.com圖像鏈接在形式..
videoArr[j]=new Array("http://ishare.rediff.com/video/entertainment/bappi-da-the-first-indian-in-grammy-jury/2684982","http://datastore.rediff.com/h86-w116/thumb/5E5669666658606D6A6B6272/v3np2zgbla4vdccf.D.0.bappi.jpg","Bappi Da - the first Indian In Grammy jury","http://mypage.rediff.com/profile/getprofile/LehrenTV/12669275","LehrenTV","(2:33)"); j = 1 videoArr[j]=new Array("http://ishare.rediff.com/video/entertainment/bebo-shahid-jab-they-met-again-/2681664","http://datastore.rediff.com/h86-w116/thumb/5E5669666658606D6A6B6272/ra8p9eeig8zy5qvd.D.0.They-Met-Again.jpg","Bebo-Shahid : Jab they met again!","http://mypage.rediff.com/profile/getprofile/LehrenTV/12669275","LehrenTV","(2:17)");
所有圖片都是不與「IMG」 tags..I也想提取如上面的HTML源不屬於即使在「IMG」的標籤圖像。
我怎樣才能做到這一點..?請幫我在這.. 感謝
爲什麼Java的?你有沒有想過開發一個瀏覽器插件? – fglez 2011-02-04 16:11:33