Embedding Into A Web Page
The applet can be displayed on the web page by making use of the deprecated applet
HTML element, or the recommended object
element. Embed
element can be used with Mozilla family browsers (embed
was deprecated in HTML 4 but is included in HTML 5). This specifies the applet's source and location. Object
and embed
tags can also download and install Java virtual machine (if required) or at least lead to the plugin page. Applet
and object
tags also support loading of the serialized applets that start in some particular (rather than initial) state. Tags also specify the message that shows up in place of the applet if the browser cannot run it due any reason.
However, despite object
being officially a recommended tag, as of 2010, the support of the object
tag was not yet consistent among browsers and Sun kept recommending the older applet
tag for deploying in multibrowser environments, as it remained the only tag consistently supported by the most popular browsers. To support multiple browsers, the object
tag currently requires JavaScript (that recognizes the browser and adjusts the tag), usage of additional browser-specific tags or delivering adapted output from the server side. Deprecating applet
tag has been criticized. Oracle now provides a maintained JavaScript code to launch applets with cross platform workarounds.
Read more about this topic: Java Applet
Famous quotes containing the words web and/or page:
“The soul knows only the soul; the web of events is the flowing robe in which she is clothed.”
—Ralph Waldo Emerson (18031882)
“There is then creative reading as well as creative writing. When the mind is braced by labor and invention, the page of whatever book we read becomes luminous with manifold allusion. Every sentence is doubly significant, and the sense of our author is as broad as the world.”
—Ralph Waldo Emerson (18031882)