You are previewing Platinum Edition Using XHTML™, XML, and Java™ 2.
O'Reilly logo
Platinum Edition Using XHTML™, XML, and Java™ 2

Book Description

Platinum Edition XHTML, XML and Java 2 is separated into several sections, each of which focuses on a specific technology, including XHTML, XML, JavaScript, Dynamic HTML, CGI programming with Perl, Server-side Programming with ASP, ColdFusion and PHP, and Java 2. Throughout the book, the authors focus on the features and benefits of each technology, giving readers a well-rounded education in current web development tools and techniques. In addition, the authors demonstrate the value of combining various technologies (such as Java and XML) for more powerful web solutions.

Table of Contents

  1. Copyright
  2. About the Authors
  3. Acknowledgments
  4. Tell Us What You Think!
  5. Introduction
  6. XHTML
    1. Web Site and Web Page Design
      1. The Many Facets of Web Design
      2. Site Usability and Accessibility
      3. Know Your Audience
      4. Considering Your Own Objectives
      5. Structuring Information
      6. Page Design Follows Site Design
      7. Testing Your Design
      8. Trends in Web Site Design
    2. Introduction to XHTML
      1. What Is XHTML?
      2. Basic Rules of XHTML
      3. Converting Your Existing HTML Content to XHTML
    3. XHTML 1.0 Element Reference
      1. Reference Scope
      2. How This Chapter Is Organized
      3. Global Attributes
      4. Event Handlers
      5. Document Structure Elements
      6. Formatting Elements
      7. List Elements
      8. Hyperlink Elements
      9. Image and Image Map Elements
      10. Table Elements
      11. Form Elements
      12. Frame Elements
      13. Executable Content Elements
    4. Image Maps
      1. What Are Image Maps?
      2. Client-Side Image Maps
      3. Server-Side Image Maps
      4. Using Server-Side and Client-Side Image Maps Together
      5. Providing a Text Alternative to an Image Map
      6. Image Map Tools
    5. Advanced Graphics
      1. Sorting Through the Graphic Possibilities
      2. Graphic Storage Formats
      3. Using the Browser-Safe Color Palette
      4. Creating Transparent GIFs
      5. Making a Transparent PNG
      6. Making an Image Fade In
      7. Creating Animated GIFs
      8. Layout Considerations When Using the <img /> Element
      9. Images as Hyperlink Anchors
      10. Images as Bullet Characters
      11. Images as Horizontal Rules
      12. Keeping File Sizes Small
    6. Tables
      1. Introduction to HTML Tables and Their Structure
      2. The Table Elements
      3. Alignment
      4. Controlling Other Table Attributes
      5. Spanning Multiple Rows or Columns
      6. Which Elements Can Be Placed in a Table Cell?
      7. Table Sections and Column Properties
      8. Tables as Design Tools
    7. Frames
      1. Introduction to Frames
      2. Reasons to Use Frames
      3. Reasons Not to Use Frames
      4. Setting Up a Frames Document
      5. Placing Content in Frames with the <frame /> Element
      6. Respecting the Frames-Challenged Browsers
      7. Creating Floating Frames
      8. Using Hidden Frames
    8. Forms
      1. Overview: Forms and CGI
      2. Creating Forms
      3. Labeling Input Fields
      4. Grouping Related Fields
      5. Disabled and Read-Only Fields
      6. Form Field Event Handlers
      7. Passing Form Data
    9. Style Sheets
      1. What Are Style Sheets?
      2. Why Style Sheets Are Valuable
      3. Different Approaches to Style Sheets
      4. Using Multiple Approaches
      5. Linking to Style Information in a Separate File
      6. Embedded Style Information
      7. Inline Style Information
      8. Tips for Style Sheet Users
      9. Style Sheets and Accessibility
      10. Looking Ahead to CSS3
  7. XML
    1. Introducing XML
      1. A First XML Document
      2. Mini Case Study
      3. Why XML?
      4. XML Dogmas Examined
      5. A Language Without Words
      6. XML Family of Technologies
      7. XML Recommendations
      8. W3C—World Wide Web Consortium
      9. Documents or Data?
    2. Creating XML Files for Use
      1. XML Document Fundamentals
      2. XML Names
      3. XML Tools
      4. XML Editors
      5. XML Parsers
      6. XSLT Processors
      7. XML Viewers
      8. Other XML Tools
      9. Planning a Project
      10. Creating a Document
    3. Parsing and Navigating XML—SAX, DOM, XPath, XPointer, and XLink
      1. Parsing XML
      2. SAX—The Simple API for XML
      3. Document Object Model (DOM)
      4. Why XPath?
      5. XPath Fundamentals
      6. XPointer Fundamentals
      7. XML Linking Language (XLink) Fundamentals
    4. Transforming XML—XSLT
      1. Why XSLT?
      2. XSLT Fundamentals
      3. Namespaces in XML
      4. XSLT Examples
      5. Troubleshooting
    5. Constraining XML—DTDs and XML Schemas
      1. Document Type Definitions (DTDs)
      2. Document Type Declaration
      3. Creating a DTD
      4. Limitations of DTDs
      5. Planning Document Structure
      6. XML Schema
    6. Formatting and Displaying XML
      1. Why Display XML?
      2. Current Browsers
      3. Browsers and Mobile Computing
      4. Using Style Sheets
      5. Cascading Style Sheets (CSS)
      6. XSL—XSLT and XSL-FO
      7. WML and WAP
      8. Aural "Display"
      9. Looking Forward
    7. Exploiting XML—XML and e-Commerce
      1. Introduction
      2. Data Exchange
      3. Discipline-Specific Markup Languages
      4. Enterprise JavaBeans
      5. Common Markup for Micropayment
      6. The ebXML Initiative
      7. BizTalk
    8. Moving Forward with XML
      1. Moving Forward
      2. Emerging XML Technologies
      3. Scalable Vector Graphics
      4. XHTML Modules
      5. Building XML Skills
      6. Integrating XML Skills
      7. Building Real-World XML Applications
      8. The Future
  8. JavaScript
    1. Introduction to JavaScripting
      1. Introduction to JavaScript
      2. The JavaScript Language
      3. Programming with JavaScript
      4. Controlling Your JavaScripts
      5. JavaScript Reserved Words
      6. Using JavaScript Statements
      7. JavaScript and Web Browsers
    2. The Document Object Model
      1. Web Browser Object Hierarchy and Scoping
      2. The window Object
      3. The location Object
      4. The history Object
      5. The document Object
      6. JavaScript Object Arrays
      7. The link, area, and anchor Objects
      8. The form Object
      9. The image Object
    3. Manipulating Windows and Frames with JavaScript
      1. Referencing Multiple Windows with JavaScript
      2. Using Window Events
      3. Window Methods for Getting User Input
      4. Filling Your Windows I: The location Object
      5. Filling Your Windows II: The document Object
      6. JavaScript Windows Example
      7. Creating and Using Frames
      8. Communicating Between Frames
      9. Using Hidden Frames
      10. JavaScript Frames Example
    4. Using JavaScript to Create Smart Forms
      1. Client-Side Form Validation
      2. XHTML Form Text Field Validation and Formatting with JavaScript
      3. Verifying Well-Formed Credit Card Numbers
      4. Netscape's Sample Form Validation Scripts
    5. Cookies and State Maintenance
      1. The Trouble with Stateless HTTP
      2. Maintaining State
      3. Cookies: An Introduction
      4. Using Cookies
      5. Other State Maintenance Options
    6. Using JavaScript to Control Web Browser Objects
      1. What Are Web Browser Objects?
      2. Referencing Web Browser Objects
      3. JavaScript Objects
      4. Netscape's LiveConnect
      5. The Netscape Packages
      6. JavaScript to Java Communication
      7. Java to JavaScript Communication
      8. JavaScript and Plug-Ins
      9. Using JavaScript to Control the Shockwave Flash Player
      10. Interfacing with ActiveX Controls with JavaScript
  9. Dynamic HTML
    1. Introduction to Dynamic HTML
      1. What Is Dynamic HTML?
      2. Web Page Layout and Content Positioning
      3. Dynamic Styles with Cascading Style Sheets
      4. Web Browser Object Model
      5. Dynamic Fonts
    2. Advanced Microsoft Dynamic HTML
      1. Microsoft's Implementation of Dynamic HTML
      2. Internet Explorer Document Object Model
      3. Dynamic HTML Events and the event Object
      4. Using Dynamic HTML with Styles
      5. Dynamic HTML and the Data Source Object
      6. Position HTML Elements with Dynamic HTML
      7. Changing HTML Documents On-the-Fly
      8. Dynamic HTML Filters
      9. Dynamic HTML Behaviors
      10. Find Out More About Dynamic HTML
    3. Advanced Netscape Dynamic HTML
      1. Different Approaches to Dynamic HTML
      2. The Main Elements of Navigator 4 Dynamic HTML
      3. JavaScript Accessible Style Sheets
      4. Content Positioning
      5. Putting the "Dynamic" in Dynamic HTML with JavaScript
      6. Animated Buttons Using Layers
      7. Dynamic HTML Pop-Up Menus
      8. Dynamic HTML with Navigator 6
    4. Cross-Browser Dynamic HTML
      1. What Is Cross-Browser Dynamic HTML?
      2. Cross-Browser Dynamic HTML Libraries
      3. Browser Detection Scripts
      4. Formatting with Style Sheets
      5. Style Sheet Positioning
      6. Dynamic Fonts
      7. Internet Explorer 5 and Navigator 6
      8. Resources on the Web
  10. Server-Side Processing
    1. Programming CGI Scripts
      1. CGI and the World Wide Web
      2. Beyond XHTML with CGI
      3. How CGI Works
      4. Where CGI Scripts Live
      5. CGI Server Requirements
      6. CGI Script Structure
      7. Planning Your Script
      8. Standard CGI Environment Variables
      9. CGI Script Portability
      10. CGI Libraries
      11. The Future of CGI Scripting
    2. Server-Side Includes
      1. What Are Server-Side Includes?
      2. SSI Specification
      3. Configuring SSI
      4. Using SSI in XHTML
      5. Common SSI Commands
      6. Sample SSI Programs
      7. Server Performance Considerations
    3. Server-Side Security Issues
      1. Scripts Versus Programs
      2. CGI Security Issues: Recognizing Problems and Finding Solutions
      3. Inside Attacks: Precautions with Local Users
      4. Using Others'CGI Scripts
    4. Survey of Web Databases
      1. Understanding Database Design
      2. Why Access a Database?
      3. Database Access Limitations
      4. Creating and Using Flat File Databases
      5. DBM Databases
      6. Relational Databases
      7. Debugging Database Applications
      8. Database Considerations
      9. Databases Available
      10. Database Tools
    5. Writing Active Server Pages
      1. Introduction to VBScript
      2. VBScript Identifiers
      3. Objects, Properties, Methods, and Events in VBScript
      4. VBScript Language Elements
      5. Testing Conditions in VBScript
      6. Executing VBScript Loops
      7. Using Other VBScript Statements
      8. VBScript Functions
      9. Active Server Pages and the Active Server Platform
      10. Intrinsic Active Server Page Objects
      11. Using the Active Data Object
      12. Using the ASP Scripting Objects
      13. Using ASP Components
      14. Extending ASP with Third-Party Components
      15. Putting It All Together: A Simple ASP Application
    6. Using ColdFusion
      1. What Is ColdFusion?
      2. Installing the ColdFusion Application Server
      3. Using the ColdFusion Administrator
      4. The ColdFusion Markup Language
      5. CFML Tags
      6. CFML Functions
      7. Using ColdFusion Studio
      8. Putting It All Together: A Sample ColdFusion Application
    7. Using PHP
      1. PHP: A New Server-Side Scripting Alternative
      2. What Is PHP?
      3. Which Servers Support PHP Scripts?
      4. Writing PHP Code
      5. Database Access with PHP
      6. The Future of PHP
  11. Java 2
    1. Introduction to Java
      1. What Is Java?
      2. What's New in Java 2?
    2. Developing Java Applets
      1. Basic Language Constructs
      2. Leveraging Java Classes and Packages
      3. Installing the SDK
      4. Building an Applet
      5. Running the Applet
      6. Stepping Through the Code
      7. Life Cycle of an Applet
      8. Sample Applets
      9. HelloApplet as a Standalone Application
    3. User Input and Interactivity with Java
      1. Interacting with People by Using Java
      2. Using the Abstract Windowing Toolkit
      3. Working with Layouts
      4. The Swing Architecture
      5. Swing Component APIs
      6. Using Swing-Specific Layouts
      7. Swing Listeners and Events
      8. Understanding Swing Events
      9. Drag and Drop
      10. Using Swing Event Listeners
      11. Understanding Swing Event Sources
    4. Graphics and Animation
      1. Displaying Graphics
      2. Displaying Graphics Primitives
      3. Displaying Colors
      4. Displaying Text
      5. Displaying Images
      6. Putting It All Together—The Art Display Applet
      7. Adding Animation
      8. Using the 2D API
      9. Java Resources on the Web
    5. Network Programming
      1. Java Simplifies Network Programming
      2. Connecting to the Internet: The URL Class
      3. The Java Socket Classes
      4. How the Internet Uses Sockets
      5. Writing Your Own Client and Server
      6. Communicating with Datagram Sockets
      7. Customized Network Solutions
      8. Will Security Considerations Disable Java Applets?
      9. Using Network Communications in Applets
    6. Security
      1. Executable Content and Security
      2. The Java Approach to Security
      3. Applets Versus ActiveX Controls
      4. The Security of Compiled Code
      5. Security in the Java Runtime System
      6. Making and Using Signed Applets
      7. Making a JAR
      8. Signing Your JARs
      9. Open Issues on Security
      10. Further References on Java and Security
    7. Server-Side Java
      1. Servlet Overview and Architecture
      2. Configuring Your Development Environment
      3. The Life Cycle of a Servlet
      4. Implementing Servlets Using JSP
    8. Java and XML
      1. Reading XML Documents
      2. Java and XML in Action
      3. Writing Extensible Server Pages
  12. Appendixes
    1. JavaScript Language Reference
      1. How This Reference Is Organized
      2. A Note About JavaScript Implementations
      3. The anchor Object [2|3|4|I]
      4. The applet Object [3]
      5. The area Object [3]
      6. The array Object [3|4|I]
      7. The button Object [2|3|I]
      8. The checkbox Object [2|3|I]
      9. The combo Object [I]
      10. The date Object [2|3|I]
      11. The document Object [2|3|I]
      12. The fileUpload Object [3]
      13. The form Object [2|3|I]
      14. The frame Object [2|3|I]
      15. The function Object [3]
      16. The hidden Object [2|3|I]
      17. The history Object [2|3|I]
      18. The image Object [3]
      19. The layer Object [4]
      20. The link Object [2|3|I]
      21. The location Object [2|3|I]
      22. The math Object [2|3|I]
      23. The mimeType Object [3]
      24. The navigator Object [2|3|I]
      25. The option Object [3]
      26. The password Object [2|3|I]
      27. The plugin Object [2|3|I]
      28. The radio Object [2|3|I]
      29. The regExp Object [3|I]
      30. The Regular Expression Object [3|I]
      31. The reset Object [2|3|I]
      32. The screen Object [4|I]
      33. The select Object [2|3]
      34. The string Object [2|3|I]
      35. The submit Object [2|3|I]
      36. The text Object [2|3|I]
      37. The textarea Object [2|3|I]
      38. The window Object [2|3|I]
      39. Independent Functions, Operators, Variables, and Literals
    2. General Reference Resource
      1. The Web as a Resource
      2. Part I, "XHTML"
      3. Part II, "XML"
      4. Part III, "JavaScript"
      5. Part IV, "Dynamic HTML"
      6. Part V, "Server-Side Processing"
      7. Part VI, "Java 2"
  13. Index