Thursday 10 November 2016

APPLET TAGS



    <APPLET …> tag supplies the name of the applet to be loaded and tells the browser how much space the applet requires. The <APPLET> tag contains several attributes that can help to integrate applet into the overall design of the web page. The syntax of applet tag is:
<APPLET
    [CODEBASE = codebase_URL ]
CODE = AppletFileName.class
[ALT = alternate_text]
    [NAME = applet_instance_name]
WIDTH = pixels
    HEIGHT = pixels
[ALIGN = alignment]
    [VSPACE = pixels]
    [HSPACE = pixels]
[<PARAM NAME = name1 VALUE = value1>]
[<PARAM NAME = name2 VALUE = value2>]
………..
………..
[Text to be displayed in the absence of Java]
</APPLET>
The attributes in [] indicates optional tag.
Attribute
Meaning
CODE=appletfilename.class
Specifies the name of the applet class to be loaded. This attribute must be specified.
CODEBASE=codebase_URL
Specifies the URL of the directory in which the applet resides.
WIDTH=pixel
Specifies the width of space on HTML page that will be used for applet. This attribute must be specified.
HEIGHT=pixel
Specifies the height of space on HTML page that will be used for applet. This attribute must be specified.
NAME=applet_instance_name
Specifies name for the applet that may be used by other applets to refer to it.
ALIGN=alignment
Specifies where on the page the applet will appear. Possible values for alignment are: TOP, BOTTOM, LEFT, RIGHT, MIDDLE, ABSMIDDLE, ABSBOTTOM, TEXTTOP, and BASELINE.
HSPACE=pixel
Used only when ALIGN is set to LEFT or RIGHT. It specifies the horizontal blank space the browser should leave surrounding the applet.
VSPACE=pixel
Used only when ALIGN is set to TOP or BOTTOM. It specifies the vertical blank space the browser should leave surrounding the applet.
ALT=alternate_text
Alternative text to be displayed in Non-Java browser.


No comments:
Write comments