2011-09-26 104 views

回答

1

看起來好像已經有一個關於從WebView獲取HTML代碼的問題。請看看是:Is it possible to get the HTML code from WebView (主要教程是在這裏:http://lexandera.com/2009/01/extracting-html-from-a-webview/

當然,一旦你的HTML代碼(串),你可以做任何你想要如更換文本你想要的!

操縱HTML字符串可以加載到視圖與下面的代碼片段:

webview.loadData(newHtmlStr, "text/html", "utf-8"); 

newHtmlStr是新的數據,並且必須URI轉義!