I am creating a web browser in Java. In this browser I am using
JEditorPane for Browser Window. I am using "setPage(String url)" method
to display the page. The browser can display the page but there are
some problems which are as mentioned::
- The browser is not displaying the java script.
- It is not displaying the Applet.
- Brows data does not show in proper way(like as a browser(Show in image)).
My code is-
JEditorPane editorPane = new JEditorPane();
String url="http://google.co.in";
editorPane.setEditable(false);
try {
editorPane.setPage(url);
} catch (IOException e) {
System.err.println("Attempted to read a bad URL: " + url);
}
}
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…