-
Chapter 1 Getting Started: Enabling Struts Development
-
Introduction
-
Downloading Struts
-
Deploying the Struts Example Application
-
Migrating from Struts 1.0 to Struts 1.1
-
Upgrading from Struts 1.1 to Struts 1.2
-
Converting JSP Applications to Struts
-
Managing Struts Configuration Files
-
Using Ant to Build and Deploy
-
Generating Struts Configuration Files Using XDoclet
-
-
Chapter 2 Configuring Struts Applications
-
Introduction
-
Using Plug-ins for Application Initialization
-
Eliminating Tag Library Declarations
-
Using Constants on JSPs
-
Using Multiple Struts Configuration Files
-
Factoring Your Application into Modules
-
Using Multiple Resource Bundles
-
Accessing Message Resources from a Database
-
Selectively Disabling Actions
-
-
Chapter 3 User Interface
-
Introduction
-
Using JSTL
-
Using the Struts-EL Tags
-
Displaying Indexed Properties
-
Using Indexed Properties on Forms
-
Using Indexed Properties in a JSTL Loop
-
Submitting a Form from an Image
-
Generating JavaScript on the Fly
-
Dynamically Changing Select Options Using JavaScript
-
Generating Dynamic Select List Options
-
Filtering Text Input
-
Generating a Set of Related Radio Buttons
-
Handling Unchecked Checkboxes
-
Handling Date Input Fields
-
Setting Tab Order
-
Generating URLs
-
Adding Request Parameters to a Link
-
Using Frames
-
Defeating Browser Caching
-
-
Chapter 4 Tables, Sorting, and Grouping
-
Introduction
-
Creating a Horizontal Bar Chart
-
Creating a Vertical Bar Chart
-
Alternating Table Row Colors
-
Sorting HTML Tables
-
Paging Tables
-
Using the Display Tag Library
-
-
Chapter 5 Processing Forms
-
Introduction
-
Creating Dynamic Action Forms
-
Setting DynaActionForm Initial Values
-
Using a List-Backed Form Property
-
Using a Map-Backed Form Property
-
Lazy Dynamic Action Forms
-
Populating Value Objects from ActionForms
-
Automatically Creating ActionForms
-
-
Chapter 6 Leveraging Actions
-
Introduction
-
Creating a Base Action
-
Relaying Actions
-
Returning the HTTP Response
-
Writing Thread-Safe Actions
-
Forwarding Requests
-
Including the Response from a Servlet or JSP
-
Changing the Current Module
-
Managing Related Operations from a Central Action
-
Submitting a Form from Localized Form Controls
-
Dispatching to Related Operations with Action Mappings
-
-
Chapter 7 Execution Control
-
Introduction
-
Performing Tasks at Application Startup
-
Tracking Client Sessions
-
Monitoring User Logins
-
Forwarding Users to Alternate Destinations
-
Forwarding Users to a Module
-
Creating a Wizard-Style Page Flow
-
Determining the Action Based on User Input
-
Using Wildcards in Action Paths
-
Preventing Double Form Submissions
-
Allowing Users to Upload Files
-
Displaying a File from the Server
-
-
Chapter 8 Input Validation
-
Introduction
-
Reusing Validator Attribute Values
-
Validating Using Regular Expressions
-
Validating Dependent Fields in Struts 1.1
-
Validating Dependent Fields in Struts 1.2
-
Validating an Indexed Property
-
Validating Dates
-
Validating Field Equality with a Custom Validator
-
Validating Field Equality in Struts 1.2
-
Validating Two or More Choices
-
Adding a Custom Validation to a Validator Form
-
Validating a Wizard Form
-
Localizing Validation Rules
-
-
Chapter 9 Exception and Error Handling
-
Introduction
-
Simplifying Exception Processing in an Action
-
Custom Processing for Declared Exceptions
-
Using Exception Error Codes
-
Using a Global Error Page
-
Reporting Errors and Messages from an Action
-
Formatting Error Messages
-
-
Chapter 10 Connecting to the Data
-
Introduction
-
Accessing JDBC Data Sources from an Action
-
Displaying Relational Data
-
Mapping SQL Data to Java Objects
-
Integrating Struts with Hibernate
-
Decoupling Your Application from External Services
-
Integrating Spring with Struts
-
Loading XML Data into Your Application
-
Refreshing Application Data
-
-
Chapter 11 Security
-
Introduction
-
Securing Actions Using a Base Action
-
Checking for User Login on Any Struts Reques t
-
Securing a JSP Page
-
Restricting Actions by Role
-
Implementing "Remember Me" Logins
-
Ensuring Security Across Your Entire Application
-
Allowing a User to Log in Automatically
-
Limiting Access for Specific URLs by Role
-
Letting the Container Manage Security
-
Mixing Application-Managed and Container-Managed Security
-
Configuring Actions to Require SSL
-
Limiting the Size of Uploaded Files
-
-
Chapter 12 Internationalization
-
Introduction
-
Detecting Browser Language Settings
-
Sharing Message Resources with JSTL
-
Using an Application-Wide Locale
-
Changing Locale on the Fly
-
Creating Localized Messages from an Action
-
Displaying Locale-Specific Text
-
Displaying Locale-Specific Images
-
Supporting Character Sets
-
Localizing Look and Feel
-
-
Chapter 13 Testing and Debugging
-
Introduction
-
Deploying an Application Automatically
-
Configuring Struts Logging
-
Adding Logging to Your Own Classes
-
Enabling Remote Debugging
-
Troubleshooting JSP Pages
-
Testing Your Actions with Mock Objects
-
Testing Your Actions in the Container
-
Testing Application Functionality
-
-
Chapter 14 Tiles and Other Presentation Approaches
-
Introduction
-
Reusing a Common Page Layout with Tiles
-
Extending Tile Definitions
-
Displaying Tiles Using a Struts Forward
-
Creating Tabbed Panes
-
Using Tiles for I18N
-
Using Tiles in a Modular Application
-
Reusing a Common Page Layout with SiteMesh
-
Integrating JavaServer Faces with Struts
-
Integrating Struts and Velocity
-
Integrating Struts and XSLT
-
-
Colophon
- Title:
- Jakarta Struts Cookbook
- By:
- Bill Siggelkow
- Publisher:
- O'Reilly Media
- Formats:
-
- Ebook
- Safari Books Online
- Print Release:
- February 2005
- Ebook Release:
- February 2009
- Pages:
- 528
- Print ISBN:
- 978-0-596-00771-3
- | ISBN 10:
- 0-596-00771-X
- Ebook ISBN:
- 978-0-596-10460-3
- | ISBN 10:
- 0-596-10460-X
Our look is the result of reader comments, our own experimentation, and feedback from distribution channels. Distinctive covers complement our distinctive approach to technical topics, breathing personality and life into potentially dry subjects. The animal on the cover of Jakarta Struts Cookbook is a tragopan. Tragopans, or horned pheasants, are found along the Himalayas from Kashmir to central and southeastern China. Male tragopans are among the world's most spectacular birds because of their brilliant array of colors and spots, long crown feathers, and blue crests. In villages near the Great Himalayan National Park, the western tragopan has earned the local name Jujurana, or "the king of the birds." There, legend has it that when this pheasant was created, every bird in the universe donated a feather to give it color and unparalleled beauty. Female tragopans, on the other hand, are rather dull looking. Even breeders sometimes find it difficult to distinguish hens of one species from those of another.
Tragopans feed on insects, leaves, sprouts, and seeds, and are thought to be monogamous. Although incubation is done entirely by the female, the male may assist in tending the chicks. Most tragopans are good breeders in captivity, adapting well to various cold-weather climates and becoming quite tame.
There are five species of tragopans, four of which are in danger of extinction due to the destruction of their habitats. Unlike most fowl, tragopans live at very high elevations ranging from 925 to 3,650 meters. In the winter, they are typically found in the thickest parts of pine trees, but during mating season, they travel upward to the extreme limits of the forest. Finding a high branch, the male western tragopan establishes a territorial perch from which he calls at five-minute intervals. His call, which some have described as similar to that of a goose or young lamb, can be heard for more than a mile. Matt Hutchinson was the production editor for Jakarta Struts Cookbook. GEX, Inc. provided production services. Darren Kelly, Mary Anne Weeks Mayo, and Claire Cloutier provided quality control.
Ellie Volckhausen designed the cover of this book, based on a series design by Edie Freedman. The cover image is a 19th-century engraving from the Dover Pictorial Archive. Emma Colby produced the cover layout with Adobe InDesign CS using Adobe's ITC Garamond font.
David Futato designed the interior layout, based on his own series design. This book was converted by Julie Hawks to FrameMaker 5.5.6 with a format conversion tool created by Erik Ray, Jason McIntosh, Neil Walls, and Mike Sierra that uses Perl and XML technologies. The text font is Linotype Birka; the heading font is Adobe Myriad Condensed; and the code font is LucasFont's TheSans Mono Condensed. The illustrations that appear in the book were produced by Robert Romano and Jessamyn Read using Macromedia FreeHand MX and Adobe Photoshop CS. The tip and warning icons were drawn by Christopher Bing. This colophon was written by Lydia Onofrei.
