|
|
| |
|
JavaServer Pages Examples
|
|
Download the JavaServer Pages Examples
|
|
You can download all the book examples for the 3rd edition,
including source code for all custom actions and beans, and install
locally.
All you need is included in this file:
jspbook3.zip.
To run the examples on your own desktop or server, you need
a Servlet 2.4/JSP 2.0 compliant container, such as
Apache Tomcat 5.0.12
or later.
Note! If you're looking for the examples for earlier editions of
the book, use these links:
-
1st edition jspbook.zip
- 2nd edition jspbook.zip
|
How to install the examples for Tomcat, or any other compliant
web container, is described in detail in the book.
Briefly, this is what you need to do to run the examples:
- Download the examples ZIP file and save it on your hard disk.
- Unpack the contents of the file with either a ZIP
utility program (such as WinZip) or the jar
command that's included in the standard Java environment.
The file contains two directories: ora and src.
-
The ora directory contains the book examples arranged
in the structure specified by the Servlet 2.2 specification
for web applications archives (WAR files), which is supported by
most containers also as an open file system structure.
For Tomcat, just copy the ora directory and all its
subdirectories under Tomcat's webapps directory.
For other containers, see their documentation for how to
install a web application.
To run
the database examples, you need to adjust the JDBC settings in
the ora/WEB-INF/web.xml, install a JDBC driver for your
database, and create the example tables. See the README file
and the book for details.
-
Restart the container and access the main example page
with a URL like:
http://localhost:8080/ora/
|
|
|