没转换以前程序运行正常 <%@ page language="java" pageEncoding="GBK"%> <html> <head> </head> <script type="text/javascript"> function openApp(){ var url = "/JasperPrintTest/TestServlet3"; document.write(""<APPLET ID="JrPrt" CODE="com.defonds.test.JRPrinterApplet.class" CODEBASE = "./" ARCHIVE = "reportprint.jar" WIDTH = "0" HEIGHT = "0">""); document.write(""<PARAM NAME = "type" VALUE="application/x-java-applet;version=1.2.2">""); document.write(""<PARAM NAME = "scriptable" VALUE="false">""); document.write(""<PARAM NAME = "REPORT_URL" VALUE ="""+url+""">""); document.write(""</APPLET>""); } </script> <body bgcolor="#FFFFFF"> <input type="button" value="测试打印" onclick="openApp();"> </body> </html> 转换以后单击button按钮报js错误 代码为 <%@ page language="java" pageEncoding="GBK"%> <html> <head> </head> <script type="text/javascript"> function openApp(){ document.write(""<object classid = "clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" codebase = "" WIDTH = "0" HEIGHT = "0" > <PARAM NAME = CODE VALUE = "com.defonds.test.JRPrinterApplet.class" > <PARAM NAME = CODEBASE VALUE = "./" > <PARAM NAME = ARCHIVE VALUE = "reportprint.jar" > <param name = "type" value = "application/x-java-applet;version=1.6"> <param name = "scriptable" value = "false"> <PARAM NAME = "type" VALUE="application/x-java-applet;version=1.2.2"> <PARAM NAME = "scriptable" VALUE="false"> <PARAM NAME = "REPORT_URL" VALUE ="/JasperPrintTest/TestServlet3"> <PARAM NAME = "SHOW_DIALOG" VALUE ="true"> <comment> <embed type = "application/x-java-applet;version=1.6" \ CODE = "com.defonds.test.JRPrinterApplet.class" \ JAVA_CODEBASE = "./" \ ARCHIVE = "reportprint.jar" \ WIDTH = "0" \ HEIGHT = "0" \ type ="application/x-java-applet;version=1.2.2" \ scriptable ="false" \ REPORT_URL ="/JasperPrintTest/TestServlet3" \ SHOW_DIALOG ="true" scriptable = false pluginspage = ""> <noembed> </noembed> </embed> </comment> </object>""); } </script> <body bgcolor="#FFFFFF"> <input type="button" value="测试打印" onclick="openApp();"> </body> </html> 我是用jdk自带的转换工具转换的,谁知道原因呢? |
|
没人知道吗?急急。。。。 |
|
我的天,没人理我….
|
|
30分 |
我代表广大不会这个问题的csdn网友们,理你一下。
|
既然都不知道,那就把分数给你吧
|