Please consider the latest edition.
-
Chapter 1 Strings
-
Introduction
-
Concatenating (Joining) Strings
-
Accessing Substrings
-
Changing String Case
-
Testing Equality of Two Strings
-
Testing String Containment Without Regular Expressions
-
Testing String Containment with Regular Expressions
-
Searching and Replacing Substrings
-
Using Special and Escaped Characters
-
Reading and Writing Strings for Cookies
-
Converting Between Unicode Values and String Characters
-
Encoding and Decoding URL Strings
-
Encoding and Decoding Base64 Strings
-
-
Chapter 2 Numbers and Dates
-
Introduction
-
Converting Between Numbers and Strings
-
Testing a Number's Validity
-
Testing Numeric Equality
-
Rounding Floating-Point Numbers
-
Formatting Numbers for Text Display
-
Converting Between Decimal and Hexadecimal Numbers
-
Generating Pseudorandom Numbers
-
Calculating Trigonometric Functions
-
Creating a Date Object
-
Calculating a Previous or Future Date
-
Calculating the Number of Days Between Two Dates
-
Validating a Date
-
-
Chapter 3 Arrays and Objects
-
Introduction
-
Creating a Simple Array
-
Creating a Multidimensional Array
-
Converting Between Arrays and Strings
-
Doing Something with the Items in an Array
-
Sorting a Simple Array
-
Combining Arrays
-
Dividing Arrays
-
Creating a Custom Object
-
Simulating a Hash Table for Fast Array Lookup
-
Doing Something with a Property of an Object
-
Sorting an Array of Objects
-
Customizing an Object's Prototype
-
Converting Arrays and Custom Objects to Strings
-
-
Chapter 4 Variables, Functions, and Flow Control
-
Introduction
-
Creating a JavaScript Variable
-
Creating a Named Function
-
Nesting Named Functions
-
Creating an Anonymous Function
-
Delaying a Function Call
-
Branching Execution Based on Conditions
-
Handling Script Errors Gracefully
-
Improving Script Performance
-
-
Chapter 5 Browser Feature Detection
-
Introduction
-
Detecting the Browser Brand
-
Detecting an Early Browser Version
-
Detecting the Internet Explorer Version
-
Detecting the Netscape Navigator Version
-
Detecting the Client Operating System
-
Detecting Object Support
-
Detecting Object Property and Method Support
-
Detecting the Browser Written Language
-
Detecting Cookie Availability
-
Defining Browser- or Feature-Specific Links
-
Testing on Multiple Browser Versions
-
-
Chapter 6 Managing Browser Windows
-
Introduction
-
Setting the Main Window's Size
-
Positioning the Main Window
-
Maximizing the Main Window
-
Creating a New Window
-
Bringing a Window to the Front
-
Communicating with a New Window
-
Communicating Back to the Main Window
-
Using Internet Explorer Modal/Modeless Windows
-
Simulating a Cross-Browser Modal Dialog Window
-
Simulating a Window with Layers
-
-
Chapter 7 Managing Multiple Frames
-
Introduction
-
Creating a Blank Frame in a New Frameset
-
Changing the Content of One Frame from Another
-
Changing the Content of Multiple Frames at Once
-
Replacing a Frameset with a Single Page
-
Avoiding Being "Framed" by Another Site
-
Assuring a Page Loads in its Frameset
-
Reading a Frame's Dimensions
-
Resizing Frames
-
Setting Frameset Specifications Dynamically
-
-
Chapter 8 Dynamic Forms
-
Introduction
-
Auto-Focusing the First Text Field
-
Performing Common Text Field Validations
-
Preventing Form Submission upon Validation Failure
-
Auto-Focusing an Invalid Text Field Entry
-
Changing a Form's Action
-
Blocking Submissions from the Enter Key
-
Advancing Text Field Focus with the Enter Key
-
Submitting a Form by an Enter Key Press in Any Text Box
-
Disabling Form Controls
-
Hiding and Showing Form Controls
-
Allowing Only Numbers (or Letters) in a Text Box
-
Auto-Tabbing for Fixed-Length Text Boxes
-
Changing select Element Content
-
Copying Form Data Between Pages
-
-
Chapter 9 Managing Events
-
Introduction
-
Equalizing the IE and W3C Event Models
-
Initiating a Process After the Page Loads
-
Determining the Coordinates of a Click Event
-
Preventing an Event from Performing Its Default Behavior
-
Blocking Double Clicks
-
Determining Which Element Received an Event
-
Determining Which Mouse Button Was Pressed
-
Reading Which Character Key Was Typed
-
Reading Which Noncharacter Key Was Pressed
-
Determining Which Modifier Keys Were Pressed During an Event
-
Determining the Element the Cursor Rolled From/To
-
Synchronizing Sounds to Events
-
-
Chapter 10 Page Navigation Techniques
-
Introduction
-
Loading a New Page or Anchor
-
Keeping a Page Out of the Browser History
-
Using a select Element for Navigation
-
Passing Data Between Pages Via Cookies
-
Passing Data Between Pages Via Frames
-
Passing Data Between Pages Via URLs
-
Creating a Contextual (Right-Click) Menu
-
Creating Drop-Down Navigation Menus
-
Providing Navigation Trail Menus
-
Creating Expandable Menus
-
Creating Collapsible XML Menus
-
-
Chapter 11 Managing Style Sheets
-
Introduction
-
Assigning Style Sheet Rules to an Element Globally
-
Assigning Style Sheet Rules to a Subgroup of Elements
-
Assigning Style Sheet Rules to an Individual Element
-
Importing External Style Sheets
-
Importing Browser- or Operating System-Specific Style Sheets
-
Changing Imported Style Sheets After Loading
-
Enabling/Disabling Style Sheets
-
Toggling Between Style Sheets for an Element
-
Overriding a Style Sheet Rule
-
Turning Arbitrary Content into a Styled Element
-
Creating Center-Aligned Body Elements
-
Reading Effective Style Sheet Property Values
-
Forcing Version 6 Browsers into Standards-Compatibility Mode
-
-
Chapter 12 Visual Effects for Stationary Content
-
Introduction
-
Precaching Images
-
Swapping Images (Rollovers)
-
Changing Text Style Properties
-
Offering Body Text Size Choices to Users
-
Creating Custom Link Styles
-
Changing Page Background Colors and Images
-
Hiding and Showing Elements
-
Adjusting Element Transparency
-
Creating Transition Visual Effects
-
-
Chapter 13 Positioning HTML Elements
-
Introduction
-
Making an Element Positionable in the Document Space
-
Connecting a Positioned Element to a Body Element
-
Controlling Positioning Via a DHTML JavaScript Library
-
Deciding Between div and span Containers
-
Adjusting Positioned Element Stacking Order (z-order)
-
Centering an Element on Top of Another Element
-
Centering an Element in a Window or Frame
-
Determining the Location of a Nonpositioned Element
-
Animating Straight-Line Element Paths
-
Animating Circular Element Paths
-
Creating a Draggable Element
-
Scrolling div Content
-
Creating a Custom Scrollbar
-
-
Chapter 14 Creating Dynamic Content
-
Introduction
-
Writing Dynamic Content During Page Loading
-
Creating New Page Content Dynamically
-
Including External HTML Content
-
Embedding XML Data
-
Embedding Data as JavaScript Objects
-
Transforming XML Data into HTML Tables
-
Transforming JavaScript Objects into HTML Tables
-
Converting an XML Node Tree to JavaScript Objects
-
Creating a New Element
-
Creating Text Content for a New Element
-
Creating Mixed Element and Text Nodes
-
Inserting and Populating an iframe Element
-
Getting a Reference to an HTML Element Object
-
Replacing Portions of Body Content
-
Removing Body Content
-
Sorting Dynamic Tables
-
Walking the Document Node Tree
-
Capturing Document Content
-
-
Chapter 15 Dynamic Content Applications
-
Introduction
-
Displaying a Random Aphorism
-
Converting a User Selection into an Arbitrary Element
-
Automating the Search-and-Replace of Body Content
-
Creating a Slide Show
-
Auto-Scrolling the Page
-
Greeting Users with Their Time of Day
-
Displaying the Number of Days Before Christmas
-
Displaying a Countdown Timer
-
Creating a Calendar Date Picker
-
Displaying an Animated Progress Bar
-
-
Appendix A Keyboard Event Character Values
-
Appendix B Keyboard Key Code Values
-
Appendix C ECMAScript Reserved Keywords
-
Colophon
- Title:
- JavaScript & DHTML Cookbook
- By:
- Danny Goodman
- Publisher:
- O'Reilly Media
- Formats:
-
- Ebook
- Safari Books Online
- Print Release:
- April 2003
- Ebook Release:
- February 2009
- Pages:
- 544
- Print ISBN:
- 978-0-596-00467-5
- | ISBN 10:
- 0-596-00467-2
- Ebook ISBN:
- 978-0-596-10377-4
- | ISBN 10:
- 0-596-10377-8
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 the JavaScript and DHTML Cookbook is a howler monkey. Howler monkeys are so named because of the very loud sounds they make, which can be heard up to two miles away. They are considered the loudest landliving animals. They have two hollow hyoid bones that allow them to make the powerful sounds they are known for.
Male howler monkeys are black, and females range from a brown to a light tan color. They have a large neckand a large lower jaw (containing the large hyoid bones), short legs, and a long, prehensile tail. All baby howler monkeys are born with brown fur, but the fur on the males eventually changes to black. These monkeys can grow up to 2 feet in length, and can weight up to 16 pounds. The males are usually significantly larger than the females.
Howlers travel and live in packs of one to three males and two to seven females. There is one dominant male in each group. They spend the majority of their time in trees. Their howling vocalizations are used to marktheir territories as well as to communicate with other packs of monkeys. Their diet consists mostly of leaves, but they also eat fruit and bugs. They are becoming an endangered species due to the shrinking size of the forests in which they live and find food. Mary Brady was the production editor and the copyeditor for the JavaScript and DHTML Cookbook. Brian Sawyer and Sarah Sherman provided quality control. John Bickelhaupt wrote the index.
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 Cuvier's Animals. Emma Colby produced the cover layout with QuarkXPress 4.1 using Adobe's ITC Garamond font.
David Futato designed the interior layout. This bookwas converted by Joe Wizda 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 bookwere produced by Robert Romano and Jessamyn Read using Macromedia FreeHand 9 and Adobe Photoshop 6. This colophon was written by Mary Brady.
