In Chapter 16, I discussed straightforward client applications that
communicate over a socket. Chapter
17 covered simple server topics. Now we turn our attention to a
variety of other client topics. First let’s look at Java-based web
applet client programs. Applets are, as you probably know, small
programs that run inside and under the control of a web browser. There’s
a discussion of
JApplet and the
Applet methods. Deploying an applet is no
different from deploying a web page—you simply copy it into the web
server directory—but you need an HTML page to invoke it (discussed in
Recipe 18.1). We then
discuss some additional client-side topics, such as loading a URL, that
apply both to applets and to applications. Other books talk about
servlets, which are programs similar to applets but designed to run
inside the process of a web server. Applet deployment requires some
considerations; see Recipe Recipe 23.6 for a means of
ensuring that a user’s browser has a Java runtime compatible with your
applet. Recipe 23.13
contains information on Java Web Start, which combines applet-like
downloading with full application capabilities.
You need to deploy a Java applet.
<applet> tag in
an HTML page.
While this is not the place for a dissertation on the details of HTML, you should at least know that HTML is a tag-based textual language for writing ...