O'Reilly logo

Web Design in a Nutshell, 2nd Edition by Jennifer Niederst Robbins

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

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.

Java’s primary contribution to the Web, however, has been in the form of Java applets, which are self-contained, mini-executable programs. These programs, named with the .class suffix, can be placed right on the web page, like a graphic.

Advantages and Disadvantages

Applets are ideal for web distribution for the following reasons:

  • They are platform-independent.

  • They download completely and run on the client, so there is no continued burden on the server.

  • Applet files are generally quite compact and download quickly.

  • They don’t require a proprietary plug-in to be installed. All the major browsers are now Java-enabled, which means chances are good that users will be able to view the applet.

Of course, every utopian technology has its darker side, and unfortunately, in the real world, browsers can be temperamental in the way they handle Java applets. Browsers are notorious for crashing in the presence of a computation-hungry applet. In general, it also takes browsers a long time to initialize Java, which tends to chase users away. There was a great buzz among web developers when Java applets first hit the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required