Open In App

HTML applet Tag

Last Updated : 21 Nov, 2024
Comments
Improve
Suggest changes
Like Article
Like
Report

The applet tag in HTML was used to embed Java applets into any HTML document. The <applet> tag was deprecated in HTML 4.01, and its support has been completely discontinued starting from HTML 5. Alternatives available in HTML 5 are the <embed> and the <object> tags. Some browsers still support the <applet> tag with the help of some additional plug-ins/installations to work.

HTML
<!DOCTYPE html>
<html>
<applet code="HelloWorld">
    <param name="message" value="HelloWorld">
</applet>

</html>

Syntax: 

<param name=parameter_name value=parameter_value>

The name assigned to the name attribute of the param tag is used by the applet code as a variable to access the parameter value specified in the value attribute. In this way, the applet is able to interact with the HTML page where it is embedded, and can work on values provided to it by the page during run-time.

Attributes:

Attribute ValuesDescription
alignSpecifies the alignment of an applet.
altSpecifies an alternate text for an applet.
archiveSpecifies the location of an archive file.
borderSpecifies the border around the applet panel.
codebaseSpecifies a relative base URL for applets specified in the code attribute.
heightSpecifies the height of an applet.
hspaceDefines the horizontal spacing around an applet.
mayscriptIndicates whether the Java applet is allowed to access the scripting objects of the web page.
nameDefines the name for an applet (to use in scripts).
vspaceDefines the vertical spacing around an applet.
widthSpecifies the width of an applet.

Next Article
Article Tags :

Similar Reads