ToC ~ Up ~ Prev ~ Next ~ Index |
Introduction to HTML Last Update: 5 January 1998 |
Netscape Navigator 2.0 and later, as well as Internet Explorer 3 and later, supports embedded applets -- programs, written in the Java programming language, that can be embeded within HTML document and executed. This embedding is done via the APPLET element, while parameters required by the applet are passed with PARAM elements. For example, consider the following markup:
<APPLET CODE="Blink.class" WIDTH=300 HEIGHT=100> <PARAM NAME="organs" VALUE="String 23"> <PARAM NAME="pk3" VALUE="3.221"> <PARAM NAME="speed" VALUE="4"> </APPLET>
Here CODE gives the name of the application to run, WIDTH and HEIGHT give the space needed by it (in pixels) and PARAM elements, within APPLET, contain paramaters to be passed to the applet -- note the similarity to FORMS. SOme other supported attributes include HSPACE and VSPACE (horizontal and vertical space to leave around applet, in pixels) and MAYSCRIPT (Netscape-only -- the presence of this attribute lets the applet communicate with JavaScript programs within the HTML document).
For more information on Java an applets see the Sun Microsystem's Java site. See also the bibliography section of these online notes.
NOTE
The APPLET element is soon to be replaced by the more generic embedding element, OBJECT. However, this element is not well supported by current browsers (Netscape or Internet Explorer 4), so you are advised to use APPLET for now.
ToC ~ Up ~ Prev ~ Next ~ Index |
Introduction to HTML © 1994-1998 by Ian Graham Last Update: 5 January 1998 |