This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 7442 - Java applets are never conforming, and sometimes don't work
Summary: Java applets are never conforming, and sometimes don't work
Alias: None
Product: HTML WG
Classification: Unclassified
Component: pre-LC1 HTML5 spec (editor: Ian Hickson) (show other bugs)
Version: unspecified
Hardware: All All
: P2 normal
Target Milestone: ---
Assignee: Ian 'Hixie' Hickson
QA Contact: HTML WG Bugzilla archive list
Keywords: NE
Depends on:
Reported: 2009-08-27 13:58 UTC by Giovanni Campagna
Modified: 2010-10-04 13:56 UTC (History)
6 users (show)

See Also:


Description Giovanni Campagna 2009-08-27 13:58:00 UTC
The object element in HTML5 has the following attributes:
while in HTML4 it had all those plus
(and others, that are not important now)
In particular for Java applets, codetype is required to instantiate the JVM (to say "this is a Java applet", archive or codebase are required to download the .jar or .class files, classid is required to find out which class implements JApplet.
On the other hand, HTML5 says that
1) authors must not use any of those attributes in an HTML5 document
2) UAs must not use any of codetype, archive, codebase to instantiate the object
This means that a document may never use Java Applets, without using the applet element, and in any case it isn't conforming.

Therefore I propose to reintroduce those attributes for the object element and to rewrite the processing model accordingly.

PS: also the data attribute was relative to codebase in HTML4 and some content may rely on it
Comment 1 Henri Sivonen 2009-08-27 14:27:43 UTC
See bug 7010.
Comment 2 Michael A. Puls II 2009-08-27 19:02:57 UTC
For Java applets, everything is done with params:

<embed type="application/x-java-applet" code="MyJavaClass" codebase="dir class file and archives are in if needed" archive="archive file if needed" mayscript="true">

<object type="application/x-java-applet">
    <param name="code" value="MyJavaClass">
    <param name="codebase" value="dir class file and archives are in if needed">
    <param name="archive" value="archive file if needed">
    <param name="mayscript" value="true">

All object and embed do is load the plug-in. The plug-in does the rest with the params it gets.

Note that the @type value is technically plug-in-dependent, but application/x-java-applet usually triggers it.

classid can be used to trigger Java for IE. @codebase (the attribute, not the param - they're different) that IE uses for fetching the Java cab file if needed is not supported as that's just an IE thing.

And of course, you can use IE conditional comments if absolutely necessary.
Comment 3 Ian 'Hixie' Hickson 2009-09-18 09:17:24 UTC
As noted in the above comments, you don't need those attributes to use <object> with Java.
Comment 4 Maciej Stachowiak 2010-03-14 14:50:15 UTC
This bug predates the HTML Working Group Decision Policy.

If you are satisfied with the resolution of this bug, please change the state of this bug to CLOSED. If you have additional information and would like the editor to reconsider, please reopen this bug. If you would like to escalate the issue to the full HTML Working Group, please add the TrackerRequest keyword to this bug, and suggest title and text for the tracker issue; or you may create a tracker issue yourself, if you are able to do so. For more details, see this document:

This bug is now being moved to VERIFIED. Please respond within two weeks. If this bug is not closed, reopened or escalated within two weeks, it may be marked as NoReply and will no longer be considered a pending comment.