This is because the local documents in the page has the following two-segment JS code will be networked loading information, comments out after it is good
<link rel= "stylesheet" href= "Http://fonts.googleapis.com/css?family=Roboto:regular,medium,thin,italic, Mediumitalic,bold "title=" Roboto ">
<script src= "Http://www.google.com/jsapi" type= "Text/javascript" ></script>
Use the following Java code to bulk annotate
/* * Remove JavaScript code that requires networking in Android documents */import Java.io.bufferedreader;import Java.io.bufferedwriter;import java.io.File ; Import Java.io.filenotfoundexception;import Java.io.filereader;import Java.io.filewriter;import Java.io.ioexception;public class Formatdoc {public static int j=1; /** * @param args */public static void main (string[] args) {File file = new file ("d:/android/a Ndroid-sdk-windows/docs/"); Searchdirectory (file, 0); System.out.println ("over"); } public static void Searchdirectory (File f, int depth) {if (!f.isdirectory ()) {String fileName = f . GetName (); if (Filename.matches (". *.{ 1}html ")) {String src= < (link rel) [=]\" (stylesheet) \ "\ n (HREF) [=]\] (HTTP)://(FONTS.GOOGLEAPIS.COM/CSS) [ ?] (family) [=] (Roboto) [:] (Regular,medium,thin,italic,mediumitalic,bold) \ "(title) [=]\" roboto\ ">"; String src1 = "<script src=\" http://www.google.com/jsapi\ "type=\" Text/javascript\ "></script>"; String DST = ""; If it is an HTML file, comment out the specific JavaScript code annotation (f, SRC, DST); Annotation (f, src1, DST); }} else {file[] fs = F.listfiles (); depth++; for (int i = 0; i < fs.length; ++i) {File file = Fs[i]; Searchdirectory (file, depth); }}}//* F to modify the contents of the file * src will be replaced content * DST will be replaced with the content of the layer */public static void annotation (File F, string src, string dst) {String content = Formatdoc.read (f); Content = Content.replacefirst (src, DST); int Ll=content.lastindexof (SRC); System.out.println (LL); Formatdoc.write (content, f); System.out.println (j + +); Return public static String read (File src) {stringbuffer res = new StringBuffer (); String line = null; try {BufferedReader reader = new BufferedreadER (new FileReader (SRC)); int i=0; while (line = Reader.readline ()) = null) {if (i!=0) {res.append (' \ n '); } res.append (line); i++; } reader.close (); } catch (FileNotFoundException e) {e.printstacktrace (); } catch (IOException e) {e.printstacktrace (); } return res.tostring (); public static Boolean write (String cont, File Dist) {try {bufferedwriter writer = new Bufferedwri ter (new FileWriter (Dist)); Writer.write (cont); Writer.flush (); Writer.close (); return true; } catch (IOException e) {e.printstacktrace (); return false; } }}
Online there is a way to remove the line of JS code through the shell, very simple and convenient, 100 times times more convenient than the Java above, but can not delete the first section JS code
Find. -name "*.html" |xargs grep-l "Jsapi" |xargs sed-i '/jsapi/d '
The other way is to break the net, or use Ie,firefox offline browsing