Sams Teach Yourself JavaServer Pages in 21 Days

Overview

Sams Teach Yourself JavaServer Pages in 21 Days offers a proven tutorial format to teach JSP in 21 example-driven lessons. This book is for Web publishing professionals migrating to JavaServer Pages for its ability to create dynamic, interactive Web sites and separate presentation from Java code running behind the scenes. The book starts by explaining the relationship between JSP and Java Servlets and the basics of JSP functions and features. You'll then learn how JSP handles data, interacts with Java components,...

See more details below
Other sellers (Paperback)
  • All (15) from $1.99   
  • New (6) from $24.69   
  • Used (9) from $1.99   
Sending request ...

Overview

Sams Teach Yourself JavaServer Pages in 21 Days offers a proven tutorial format to teach JSP in 21 example-driven lessons. This book is for Web publishing professionals migrating to JavaServer Pages for its ability to create dynamic, interactive Web sites and separate presentation from Java code running behind the scenes. The book starts by explaining the relationship between JSP and Java Servlets and the basics of JSP functions and features. You'll then learn how JSP handles data, interacts with Java components, tracks users, and more. Later chapters discuss debugging, working with databases, XSLT and XML, using the Struts framework from Apache, handling binary data like graphics, and deploying JSP applications. Each topic is illustrated with many working examples that the reader can understand and put to work immediately. Throughout the book the author provides pointers to upcoming developments in JSP 2, to ensure that you are prepared for changes in the new version.

Read More Show Less

Product Details

  • ISBN-13: 9780672324499
  • Publisher: Sams
  • Publication date: 10/2/2002
  • Series: Sams Teach Yourself Series
  • Pages: 720
  • Product dimensions: 7.40 (w) x 9.10 (h) x 1.60 (d)

Meet the Author

Steven Holzner is the author of more than 70 books on programming, and has been writing on Java topics ever since Java has been around. His books have sold more than 1.5 million copies and have been translated into 16 languages around the world. He has a Ph.D. from Cornell University, has been on the faculty of both Cornell and MIT, and is a former contributing editor to PC Magazine. He's long used JSP in commercial environments, and specializes in Web development.

Read More Show Less

Table of Contents

(NOTE: Each chapter concludes with a Summary, Q&A, and Workshop.)

Introduction.

WEEK 1. AT A GLANCE.

Day 1. Getting Started!


What Are JavaServer Pages Good For? It All Starts with Java. The Tomcat Server. Creating Web Documents. A Brief History of JSP. Dissecting Our First JSP. Overview of JSP Syntax. Online JSP Resources.

Day 2. Handling Data and Operators.


Java in JSP. The JSP Programming Environment. Handling Data in JSP. Creating Variables. Initializing Variables. Data Types. Converting Between Data Types. Strings. Creating Strings. Strings Are Objects. Determining String Length. Creating and Working with Arrays. Working with Operators. Assignment Operators. Incrementing and Decrementing Operators. Multiplication and Division Operators. Addition and Subtraction Operators. Relational Operators. Logical Operators. Understanding Operator Precedence.

Day 3. Branching, Looping, and Creating Methods.


Branching Statements. Loops. Creating Methods.

Day 4. Reading Data from Web Pages: Buttons and Text Fields.


HTML Controls. HTML Forms. Submitting Forms. Sending Data to the Server. Using request Objects. Reading Data on the Server. Using Text Fields. Using Text Areas. Using Password Controls. Using Hidden Controls. Using Buttons. JSP to JSP—Navigating Directly to JSP Pages. Using Multiple Forms.

Day 5. Reading Data from Web Pages: Check Boxes, Radio Buttons, and Select Controls.


Using Check Boxes. Using Radio Buttons. Selecting and Deselecting Check Boxes and Radio Buttons in Code. Using Select Controls. Using Multiple-Selection Select Controls. Check Box Groups. Uploading Files. Image Controls. Using &#lt;jsp:forward&#gt;. Creating Image Maps. Using Named Targets. Getting All Parameter Names. Getting Request Header Information. Reset Buttons.

Day 6. Creating JSP Components: JavaBeans.


Creating a Java Class. Creating a Constructor. Creating a Method. Compiling a Java Class. Installing a Compiled Java Class. Using a Compiled Java Class. Creating a Package. Using a Package. Passing Data to a Constructor. Using &#lt;jsp:useBean&#gt;. Creating a Read-Only Property. &#lt;jsp:getProperty&#gt;: Getting a Property Value. Creating a Read/Write Property. &#lt;jsp:setProperty&#gt;: Setting Property Values. Creating Private Methods. Java Utility Classes: Working with Dates.

Day 7. Tracking Users with Sessions and Cookies.


Using Hidden Controls. The Cookie Class. The HttpServletResponse Interface. Creating a Cookie. Reading a Cookie. Setting and Reading a Cookie in the Same Page. Using Sessions. Creating a Session. Setting Session Timeouts. Using Applications. Using Sessions, Applications, and JavaBeans.

WEEK 2. AT A GLANCE.

Day 8. Handling Errors.


Syntax Errors. Runtime Errors. Exceptions. Using try/catch Blocks. Handling Specific Exception Types. Catching Multiple Exceptions. Nesting try/catch Statements. Throwing Exceptions Yourself. Throwing Exceptions from Methods. Creating a Custom Exception Object. Printing to the Server Console. Using Log Files. Using JSP Error Pages. Using JSP Error Pages: The exception Object. Using JSP Error Pages: request Object Attributes.

Day 9. Using Custom JSP Tags.


Tag Libraries. The Request Tag Library. Tag Library Descriptor Files. Creating a Simple Tag.

Day 10. Creating Custom Tags.


A Simple Text-Inserting Tag. Creating and Supporting Attributes in Custom Tags. Iterating Tags. Cooperating Tags. Using Scripting Variables.

Day 11. Creating More Powerful JavaBeans.


Why Inheritance? Using Inheritance. Using Access Specifiers. Calling Superclass Constructors. Overloading Methods. Overriding Methods. Using Superclass Variables with Subclassed Objects. Using Runtime Polymorphism. Creating Abstract Classes. Using Interfaces for Multiple Inheritance.

Day 12. Creating Servlets.


Using &#lt;jsp:plugin&#gt;. Creating Java Servlets. Using the response Object. Using the request Object. The Life Cycle of a Servlet. Creating Web Applications with Servlets. Using Servlet Configurations and Contexts.

Day 13. Creating More Powerful Servlets.


Sessions and Servlet Contexts. Forwarding Requests to Other Web Resources. Including Output from Other Web Resources. Handling Forwards and Includes. JSP Model 1 Architecture. JSP Model 2 Architecture. Supporting User Authentication. Using Cookies in Servlets. Thread Safety.

Day 14. Using Filters.


Understanding Filters. Creating a Simple Filter. Filtering JSP Pages. Creating Filter Chains. Using Initialization Parameters. Inserting Text Into the Response. Logging. Using Filters for User Authentication. Restricting Access.

WEEK 3. AT A GLANCE.

Day 15. Handling Files on the Server.


Using Tomcat Logging. Using the File Class. Streams, Readers, and Writers. Working with Text Files. Writing Text Files. Reading Text Files. Working with Binary Files. Writing Byte Data to Files. Reading Byte Data from Files. Writing Objects to Files. Reading Objects from Files.

Day 16. Getting Started with Databases.


What Are Databases? Java Database Connectivity. JDBC Drivers. Creating Connections. Using Structured Query Language.

Day 17. Working with Databases.


Data Lookup. The ResultSet Methods. Navigating in a RecordSet. Setting Cursor Type. Getting Information About a Result Set. Joining Tables. Creating and Filling Tables. Updating Data.

Day 18. Using


Handling

Day 19. Using Struts.


Putting Struts to Work. Getting Struts. Creating the View. Creating Custom Tags to Supply Data. Creating the Controller Adapter. Accessing Data in the Results Page. Creating the Model.

Day 20. Creating Images on the Fly and Handling Internet Programming.


Creating an Image on the Fly. Drawing in Response to User Actions. Drawing Images. Embedding Images in HTML Documents. Internet Programming—Interacting Directly with Servers. Creating Client/Server Applications.

Day 21. Client-Side Programming and Deploying Your Projects.


Working with JavaScript. Creating a '&#lt;SCRIPT&#gt;' Element. Creating Variables. JavaScript Operators. Branching Statements. JavaScript Loops. JavaScript Functions. Handling Events in JavaScript. Deploying Your Web Applications.

Appendix A. Answers to the Quiz Questions.

Read More Show Less

Customer Reviews

Be the first to write a review
( 0 )
Rating Distribution

5 Star

(0)

4 Star

(0)

3 Star

(0)

2 Star

(0)

1 Star

(0)

Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation

Reminder:

  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

 
Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously

    If you find inappropriate content, please report it to Barnes & Noble
    Why is this product inappropriate?
    Comments (optional)