Read an Excerpt
Part 1: JSP Foundations
Module 1:Introduction to Internet TechnologiesCommon Platform HTML provides a simple way to program applications within the browser page itself, thereby transforming it from a single application into an application platform.
Ease of Application Installation, Deployment, and Training
Web applications require no installation beyond installation of the browser. (And these days, the browser is often bundled with the operating system.) The popularity of the Web browser has also achieved a kind of critical mass-so many applications use a browser that people understand and feel comfortable with the browser as their platform. People rarely need much training in the mechanics of using a Web browser.
The popularity of browser applications does not mean that users are completely happy with their limitations. Most recent developments in the browser and the Web server aim to overcome the limits of the basic Web technology. Although this book describes JavaServer Pages, a server technology, let us briefly address browser technologies.
Extending the Web BrowserIn recent years, various vendors have spent great effort extending the capabilities of the browser as an application interface. This usually happened under the auspices of making browser pages "more dynamic." The most important of these client-side extensions have been these:
- Helper applications
- Browser plug-ins
- Dynamic HTML
- Java applets
The MIME standard that provides the basic scheme for HTTP request formatting also provides the basis for launching helper applications. The idea is that the browser passes MIME format types that it cannot handle to helper applications.
Recently, helper application functionality has tended to migrate into browser plug-ins. We discuss plug-ins next.
Browser plug-ins seamlessly extend browser functionality so that they appear to be part of the browser itself. For example, Adobe Software provides a plug-in for viewing Adobe's Portable Document Format (PDF). Other plug-ins support audio and video formats. Real Networks, for example, has plug-ins to play RealAudio and RealVideo files directly in the browser. Dozens of such plug-in programs now exist for both Netscape and Internet Explorer. Such plug-ins are loaded into the browser's own address space for execution. Vendors deploy plug-ins in browsers as shared libraries.
Shared libraries are specially packaged units of code (usually written in C or C++) that can be loaded and executed in an application at runtime. On Microsoft Windows platforms, shared libraries use Microsoft's Dynamic Link Library (DLL) format that has a All file extension. On UNIX platforms, shared libraries use the Dynamic Shared Object (DSO) format that has a .so file extension.
Dynamic HTML also provides access to a browser page's Document Object Model (DOM). DOM is the internal representation of the elements of a page, along with their attributes. Dynamic HTML supports runtime access to some of these elements and in some cases, enables runtime modifications. For example, suppose we have this page element:
...HTML has a low level of standardization. Microsoft added support for its proprietary technologies, ActiveX and VBScript, which Netscape does not support. Both Netscape and Internet Explorer support CSS, but to different degrees for different features. Both the event model and DOM for Internet Explorer and Netscape differ, making cross-platform use of DHTML quirky. (See http : / /www. dhtml zone. com/.)
- Dynamic linking of program functionality into a running application using a network download
- Independence from any CPU platform
- Guaranteed security from viruses
From that quiet beginning as Oak, Java has captured unprecedented mindshare among programmers. Initially, this popularity focused on the client side, especially Java applets.
The idea behind applets was to provide full-featured programming capabilities to browser applications without sacrificing security. Both Netscape and Microsoft licensed Java and integrated it into their respective browsers. Today, Sun provides a Java plug-in for both browser platforms. Special HTML tags invoke the plug-in to load applets into a Java virtual machine (JVM). This plug-in bridges the browser and an external JVM. The Sun Java plug-in removes developer dependence on the "out-of-the-box" versions of the Java Virtual MaclAne supported by browser vendors. This allows developers to remain current with the Java releases. For example, at this time you must use the Sun plug-in to run Java 2 applets in a browser....