Book excerpt: Ajax and the dynamic double combo

Book excerpt: Ajax and the dynamic double combo

Dave Crane and Eric Pascarello with Darren James

Although Ajax is neither new (debuting in 1998 with Outlook Web Access) nor a technology (in fact, it's a way to use established Web technologies), Ajax programming requires a learning curve surpassing that of a new technology, since it requires as much unlearning as learning. Ajax also attracts different types of IT professionals; there are enterprise developers who want to brush up on improving presentation layers, there are graphic designers and desktop developers aiming to build back-end applications, and there are system admins called on by end users to build nifty UIs.

Ajax in Action by Dave Crane and Eric Pascarello with Darren James, the latest installment of Manning Publication Co.'s In Action series, reaches out to each type of Ajax-ready developer. The book is divided into four parts that provide an overview of why Ajax can be successful, explain the core technologies behind Ajax, describe how to build production-ready software and present five step-by-step projects that use Ajax. Client-side code examples are JavaScript, the underlying language behind Ajax, while server-side code is present in PHP, Java, C#, and Visual Basic .NET.

Chapter 9, "Dynamic double combo," is the first of the chapters that presents a step-by-step development project.

    Requires Free Membership to View

    When you register, you'll begin receiving targeted emails from my team of award-winning writers. Our goal is to provide a unique online resource for developers, architects and development managers tasked with building and maintaining enterprise applications using Visual Basic, C# and the Microsoft .NET platform.

    Hannah Smalltree, Editorial Director

    By submitting your registration information to SearchWinDevelopment.com you agree to receive email communications from TechTarget and TechTarget partners. We encourage you to read our Privacy Policy which contains important disclosures about how we collect and use your registration and other information. If you reside outside of the United States, by submitting this registration information you consent to having your personal data transferred to and processed in the United States. Your use of SearchWinDevelopment.com is governed by our Terms of Use. You may contact us at webmaster@TechTarget.com.

The title refers to a double-combination linked list, in which the contents of one selection are dependent on what has been selected in a second list. The project outlined in this chapter enhances simple HTML forms with Ajax by using the data entered in one drop-down list to populate a second list by making a background request to the server. The chapter covers the client-side JavaScript, the server-side Visual Basic .NET and the data exchange format needed for this solution, describes how to refactor the code and make it a reusable component, and shows how to create dynamic select boxes.

Read this sample chapter from Ajax in Action in this PDF.

Learn more about Ajax application security in this Q&A with co-author Eric Pascarello.

 


Excerpted from Ajax in Action by Dave Crane and Eric Pascarello with Darren James (ISBN: 1-932-3946-13). Copyright 2005, Manning Publications Co.. All rights reserved.

Visit the Author Forum for Ajax in Action.

This was first published in January 2006

Disclaimer: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.