HTML <applet> tag
Java has multiple small applications which are often referred to as applets which are written in Java programming.
The <applet> tag was used to embed Java applets on the HTML document.
As the <applet> tag is not supported in HTML4 or HTML5, it is best to use the <object> tag.
If you do not wish to use the <object> element also, then you can also use the <embed> tag.
Default CSS Value
How Browser will display
Difference between HTML4.01, XHTML and HTML5
|This tag is deprecated in HTML4 with all its attributes||NA||Not supported in HTML5|
|code||This uses a URL to set the file name of the Java applet|
|height||To set the display area of the height of the applet|
|width||To set the display area of the width of the applet|
|align||It is used to align the applect with respect to its nearby elements. The alignment can takes values as - left, top, right, bottom, center, or baseline.|
|alt||This shows an alternative text to display to the user when the browser does not support this tag.|
|archive||Sets the URL of the archive file.|
|codebase||Sets the relative base URL for the code attribute's applets.|
|hspace||To specify the horizontal space around the Java applet.|
|vspace||To specify the vertical space around the Java applet.|
|object||To refer the name of the serialized representation of the Java applet.|
It is mandatory to set the code, width and height attributes while using this tag.
The <applet> tag supports Global attributes.
The <applet> tag supports Event attributes.
<object> & <embed> tags.