gpt4 book ai didi

java - 小程序标签与对象标签

转载 作者:行者123 更新时间:2023-11-30 11:37:59 25 4
gpt4 key购买 nike

根据 W3Schools,HTML5 不支持 HTML applet 标签。需要用<Object>标记而不是 <applet>标签。有关更多详细信息,请点击此链接:http://www.w3schools.com/tags/tag_applet.asp http://dev.w3.org/html5/spec/obsolete.html#the-applet-element
第 11.2 点不合格特征所以,我继续更改代码。下面的代码与 <APPLET> 一起工作标签:

<Applet 
style = "position:absolute;border:0px;left:184;top:95;height:180;width:364;"
code = "jtreeviewapplet.JTreeViewAppletMain.class"
name = "TreeView"
id = "TreeView"
hspace = "0"
vspace = "0"
align = "top"
archive = "/Project/HTML/ABC/XYZ.jar,/Project/HTML/ABC/ABC.jar"
MAYSCRIPT>


<PARAM NAME="onSelected" VALUE="onSelect_Handler">
<PARAM NAME="onFinishNormalize" VALUE="onFinishNormalize_Handler">
</Applet>
Here is the snippet; I changed <APPLET> tag to <OBJECT> tag so as to support HTML5 in future:
<OBJECT type=" application/x-java-applet"
style = "position:absolute;border:0px;left:184;top:95;height:180;width:364;"
name = "TreeView"
id = "TreeView"
hspace = "0"
vspace = "0"
align = "top"
>
<PARAM name="code" value=”jtreeviewapplet.JTreeViewAppletMain.class”>
<PARAM name="codebase" value="/Project/HTML/ABC/">
<PARAM name="archive" value=" XYZ.jar">
<PARAM name="archive" value=" ABC.jar">
<PARAM name="scriptable" value="true">
<PARAM NAME="onSelected" VALUE="onSelect_Handler">
<PARAM NAME="onFinishNormalize" VALUE="onFinishNormalize_Handler">
</OBJECT>

更改 <applet> 后标记为 <object>标记,我的小程序本身没有加载,它为 jtreeviewapplet.JTreeViewAppletMain.class 提供类未找到异常。(注意:对于工作和非工作状态,我正在使用最新的 JDK 1.7 update 9 来编译代码,在我的系统中我有最新的 JRE1.7 update 9 来运行小程序代码。我正在使用 InternetExplorer 8 和 InternetExplorer 9浏览器)

最佳答案

仅用 object 替换 applet 是不够的。阅读http://www.ailis.de/~k/archives/63-How-to-use-Java-applets-in-modern-browsers.html举个例子。

关于java - 小程序标签与对象标签,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13801116/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com