Book description
Ajax, the popular term for Asynchronous JavaScript and XML, isone of the most important combinations of technologies for webdevelopers to know these days. With its rich grouping oftechnologies, Ajax developers can create interactive webapplications with XML-based web services, using JavaScript in thebrowser to process the web server response.
Taking complete advantage of Ajax, however, requires somethingmore than your typical "how-to" book. What it calls for is AjaxHacks from O'Reilly. This valuable guide provides direct,hands-on solutions that take the mystery out of Ajax's manycapabilities. Each hack represents a clever way to accomplish aspecific task, saving you countless hours of searching for theright answer.
A smart collection of 80 insider tips and tricks, AjaxHacks covers all of the technology's finer points. Want tobuild next-generation web applications today? This book can showyou how. Among the multitude of topics addressed, it shows youtechniques for:
Using Ajax with Google Maps and Yahoo Maps
Displaying Weather.com data
Scraping stock quotes
Fetching postal codes
Building web forms with auto-complete functionality
Ajax Hacks also features a number of advanced hacks foraccelerated web developers. Discover how to create huge,maintainable bookmarklets, how to use client-side storage for Ajaxapplications, and how to call a built-in Java object fromJavaScript using Ajax. The book even addresses best practices fortesting Ajax applications and improving maintenance, performance,and reliability for JavaScript code.
The latest in O"Reilly's celebrated Hacks series, AjaxHacks smartly complements other O'Reilly titles such as HeadRush Ajax and JavaScript: The Definitive Guide.
Table of contents
- A Note Regarding Supplemental Files
- Foreword
- Credits
- Preface
-
1. Ajax Basics
- It’s Not a Floor Wax
- Handle with Care
- XMLHttpRequest
- 1. Detect Browser Compatibility with the Request Object
- 2. Use the Request Object to POST Data to the Server
- 3. Use Your Own Library for XMLHttpRequest
- 4. Receive Data as XML
- 5. Get Plain Old Strings
- 6. Receive Data as a Number
- 7. Receive Data in JSON Format
- 8. Handle Request Object Errors
- 9. Dig into the HTTP Response
- 10. Generate a Styled Message with a CSS File
- 11. Generate a Styled User Message on the Fly
-
2. Web Forms
- 12. Submit Text Field or textarea Values to the Server Without a Browser Refresh
- 13. Display Text Field or textarea Values Using Server Data
- 14. Submit Selection-List Values to the Server Without a Round Trip
- 15. Dynamically Generate a New Selection List Using Server Data
- 16. Extend an Existing Selection List
- 17. Submit Checkbox Values to the Server Without a Round Trip
- 18. Dynamically Generate a New Checkbox Group with Server Data
- 19. Populate an Existing Checkbox Group from the Server
- 20. Change Unordered Lists Using an HTTP Response
- 21. Submit Hidden Tag Values to a Server Component
- 3. Validation
-
4. Power Hacks for Web Developers
- 28. Get Access to the Google Maps API
- 29. Use the Google Maps API Request Object
- 30. Use Ajax with a Google Maps and Yahoo! Maps Mash-up
- 31. Display a Weather.com XML Data Feed
- 32. Use Ajax with a Yahoo! Maps and GeoURL Mash-up
- 33. Debug Ajax-Generated Tags in Firefox
- 34. Fetch a Postal Code
- 35. Create Large, Maintainable Bookmarklets
- 36. Use Permanent Client-Side Storage for Ajax Applications
- 37. Control Browser History with iframes
- 38. Send Cookie Values to a Server Program
- 39. Use XMLHttpRequest to Scrape an Energy Price from a Web Page
- 40. Send an Email with XMLHttpRequest
- 41. Find the Browser’s Locale Information
- 42. Create an RSS Feed Reader
-
5. Direct Web Remoting (DWR)for Java Jocks
- 43. Integrate DWR into Your Java Web Application
- 44. Use DWR to Populate a Selection List from a Java Array
- 45. Use DWR to Create a Selection List from a Java Map
- 46. Display the Keys/Values from a Java HashMap on a Web Page
- 47. Use DWR to Populate an Ordered List from a Java Array
- 48. Access a Custom Java Object with JavaScript
- 49. Call a Built-in Java Object from JavaScript Using DWR
- 6. Hack Ajax with the Prototype and Rico Libraries
-
7. Work with Ajax and Ruby on Rails
- Sensible MVC
- 55. Install Ruby on Rails
- 56. Monitor Remote Calls with Rails
- 57. Make Your JavaScript Available to Rails Applications
- 58. Dynamically Generate a Selection List in a Rails Template
- 59. Find Out Whether Ajax Is Calling in the Request
- 60. Dynamically Generate a Selection List Using Database Data
- 61. Periodically Make a Remote Call
- 62. Dynamically View Request Information for XMLHttpRequest
- 8. Savor the script.aculo.us JavaScript Library
-
9. Options and Efficiencies
- 68. Fix the Browser Back Button in Ajax Applications
- 69. Handle Bookmarks and Back Buttons with RSH
- 70. Set a Time Limit for the HTTP Request
- 71. Improve Maintainability, Performance, and Reliability for Large JavaScript Applications
- 72. Obfuscate JavaScript and Ajax Code
- 73. Use a Dynamic script Tag to Make Web Services Requests
- 74. Configure Apache to Deal with Cross-Domain Issues
- 75. Run a Search Engine Inside Your Browser
- 76. Use Declarative Markup Instead of Script via XForms
- 77. Build a Client-Side Cache
- 78. Create an Auto-Complete Field
- 79. Dynamically Display More Information About a Topic
- 80. Use Strings and Arrays to Dynamically Generate HTML
- Index
- About the Author
- Copyright
Product information
- Title: Ajax Hacks
- Author(s):
- Release date: March 2006
- Publisher(s): O'Reilly Media, Inc.
- ISBN: 9780596101695
You might also like
book
Ajax: The Definitive Guide
Is Ajax a new technology, or the same old stuff web developers have been using for …
book
Ajax Security
The Hands-On, Practical Guide to Preventing Ajax-Related Security Vulnerabilities More and more Web sites are being …
book
Professional Ajax, 2nd Edition
Professional Ajax 2nd Edition provides a developer-level tutorial of Ajax techniques, patterns, and use cases. The …
book
Understanding AJAX: Using JavaScript to Create Rich Internet Applications
AJAX: fast mastery for experienced Web developers! Already an experienced Web developer? Apply your skills in …