您的位置:首页 > 移动开发

applet通过网页发布的方法

2010-12-06 20:17 134 查看
applet和一般的class不一样,一般需要调用的class都是放在了WEB-INF/classes下面,或者WEB-INF/lib下面。

但是网页寻找applet的方式和寻找一般html文件一样。

网页和调用的applet在同一个目录的情况

<applet code=Test.class width="100" height="100">

</applet>

网页和调用的applet在不同目录的情况,使用codeBase指定applet所在目录

<applet code=Test.class codeBase="javaChart" width="100" height="100">

</applet>

applet打包在jar文件的情况,使用archives指定jar文件

<applet code=Test.class codeBase="javaChart" archives="test.jar" width="100" height="100">

</applet>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: