简体   繁体   中英

Java Applet on Mac OS (Snow Leopard) not working after most recent update

My web app and its applet have been working for years on multiple platforms and browsers. It wasn't until the recent Snow Leopard update (10.6.8 Update 16) where the applet stopped working on Safari (5.1.9). The technique I've used is described here under "Deploying Applets in a Mixed-Browser Environment":

http://download.java.net/jdk8/docs/technotes/guides/jweb/applet/using_tags.html

This technique basically uses both OBJECT and EMBED. OBJECT works for IE and EMBED works for webkit based browsers, like Safari.

I've tried to track down where things are going wrong with Update 16. I've tried Safari with each option: EMBED, OBJECT, and APPLET. EMBED which used to work no longer seems to work. Strangely APPLET does work. Note I can't get FF and Chrome to show the applet at all on Mac.

I'd prefer to not use APPLET because that creates an opportunity that I break all the other browsers that do work.

Does anyone know what Apple has done to suddenly make EMBED no longer work?

Here is the code:

<HTML>
<HEAD>
<TITLE>Applet Test</TITLE>
</HEAD>
<BODY>

<OBJECT
    classid="clsid:CAFEEFAC-0016-0000-FFFF-ABCDEFFEDCBA"
    width="250"
    height="400"
    name="ImagerAppletIE"
    align="top"
    vspace="0"
    hspace="0">                
    <PARAM name="CODE" value="com.mycompany.myapp.Imager.ImagerApplet"/>
    <PARAM name="CODEBASE" value="http://myapp.mycompany.com/classes"/>
    <PARAM name="NAME" value="ImagerApplet"/>
    <PARAM name="type" value="application/x-java-applet;version=1.6"/>
    <PARAM name="imageURL" value="http://app.mycompany.com/images/fooimage.jpg"/>
     <COMMENT>
        <EMBED ID="ImagerAppletFF"
            TYPE="application/x-java-applet;version=1.6"
            JAVA_CODE="com.mycompany.myapp.Imager.ImagerApplet"
            JAVA_CODEBASE="http://myapp.mycompany.com/classes"
            NAME="ImagerAppletFF"
            width="250"
            height="400"
            align="top"
            vspace="0"
            hspace="0"
             IMAGEURL = "http://app.mycompany.com/images/fooimage.jpg"
            <NOEMBED>
                Applets not supported.
            </NOEMBED>
        </EMBED>
    </COMMENT>
</OBJECT>

</BODY>
</HTML>

The best way to deploy a JWS app. or applet is to use the Deployment Toolkit Script . It will write an applet , object or embed element as per what that (version of that) browser requires.

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