Open In App
Related Articles

HTML | <applet> code Attribute

Improve
Improve
Improve
Like Article
Like
Save Article
Save
Report issue
Report
The <applet> code attribute specifies a relative URL for applets java file to be loaded and executed. It is used to link a Java applet to the concerned HTML document. It specifies the file name of the Java applet. Note : The <applet> tag is not supported in HTML5.

Syntax:
<applet code = "file_name"> 
....
</applet> 
Attribute Values: It contains a string value that represents the name of the java File that embedded in the HTML Document. Example:
<!DOCTYPE html> 
<html
    <applet code="HelloWorld" 
                width=200 
                height=60
    </applet>
</html>

                    
Explanation: Here, HelloWorld is the class file, which contains the applet. The width and height attributes determine the width and height of the applet in pixels when it is opened in the browser. Supported Browsers: The browser supported by <applet> tag are listed below:
  • Firefox
  • Safari

Last Updated : 21 Jan, 2022
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads