A Complete Guide to Web Design

(やまだぃちぅ) #1
370 Chapter 21 – Interactivity

Java Applets


Web Design in a Nutshell, eMatter Edition

Thebgcolorparameter as described earlier can also be used with the<object>
tag, however, it is formatted as follows and added within the<object> tags:
<PARAM NAME="BGCOLOR" value="#33CC00">

The <noembed> tag

As mentioned in the Flash section, the<noembed>tag is used to provide an alter-
native image or text message for browsers that do not recognize the<embed>tag
(at this point, that’s only Netscape 1.0 and Internet Explorer 1.0 and 2.0). The vast
majority of browsers in use today will ignore the contents of the<noembed>tag
entirely, without basing it on the availability of a specific plug-in.
If you choose to include it, the<noembed>tag is placed after the<embed>tag and
looks like this:
<EMBED>...</EMBED><NOEMBED>This material requires a plug-in
capable browser.</NOEMBED>

Putting it together for all browsers

To make your Shockwave movie available to the maximum number of users, it is
recommended that you use the<embed>and<object>tags. It is important to put
the<embed>and <noembed>tags within the <object>tags so that Internet
Explorer users don’t get two copies of your movie.

Do not use quotation marks within the <embed>tag when it is
placed within an<object>tag. The quotation marks will cause the
<object> tag to choke.

The following code places a Shockwave movie on a web page:
<OBJECTCLASSID="clsid:166B1BCA-3F9C-11CF-8075-444553540000"
CODEBASE="http://active.macromedia.com/director/cabs/sw.
cab#version=6,0,0,0" WIDTH="300" HEIGHT="150" NAME="MovieName">
<PARAM NAME="SRC" VALUE="movie.dcr">

<EMBED SRC=movie.dcr WIDTH=300 HEIGHT=150PLUGINSPAGE=http://www.
macromedia.com/shockwave/>
</EMBED>
<NOEMBED> This material requires a plug-in capable browser.
</NOEMBED>
</OBJECT>

Java Applets


Java is an object-oriented programming language developed by Sun Microsystems
(http://www.sun.com). It should be noted that it is not related to JavaScript, which
is a scripting language developed by Netscape Navigator to run within an HTML
document in a browser. Because Java is a full programming language (like C or
C++), it can be used to create whole applications.
Free download pdf