简体   繁体   中英

how to test java applets with html?

I need a test server to upload html files with java applets. I was told to try to set up apache but i cannot find an executable from the official download page ( http://httpd.apache.org/download.cgi ). Is there another ways to have a test server ? I've read that html pages containing applets can be opened from the local file system without having to use apache but since i'm really new to networking i don't know how to do this.

Use applet viewer. Then you don't need to worry about servers nor creating HTML pages.

Some important points on this for applet development/testing

  1. Applet should be signed with a valid code signing certificate

  2. You should have latest JRE.
    NOTE: Chrome and other browsers are doing away with NPAPI plugins, so jre plugins may not be there. So you cannot run on Chrome. Although there is as workaround with which you can enable JRE plugin explicitly.

  3. Load applet in html page as below.. <applet id="any id" width="80" height="80" code="com.abc.def.class" archive="applet.jar" codebase="/path/appletfolder/">

    Note: applet tag is deprecated in html5. Use embed or object instead.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM