Newsletter:

(Article) Building Ajax-enabled auto-complete and cascading drop-down controls

Article : Building Ajax-enabled auto-complete and cascading drop-down controls

Description
Build Asynchronous JavaScript + XML (Ajax) controls that can be used in business-line applications. These configurable JSP TagLib-based controls leverage JavaScript Serialized Object Notation (JSON), JavaScript, and CSS. Because they are standard JSP TagLib controls, find out how you can easily drop them into any application to provide more intuitive and responsive user interfaces. 

Two key technologies enable next-generation Web sites: Ajax and JSON. Business-line applications can benefit from these technologies to provide more intuitive and responsive user interfaces. This article describes how to add Ajax and JSON to Java™ Platform, Enterprise Edition (Java EE) Web applications by building reusable JSP TagLib controls based on Ajax.

Within the article, I show how to build a cascading drop-down control that dynamically populates values in an HTML SELECT control based on other form field values. I also describe how to build an auto-complete control, similar to Google Suggest, that displays a suggestion list that is updated in real time as a user types. You'll build the controls by integrating JSON, JavaScript, CSS, HTML, and Java EE technologies.

Technical overview
The primary design goals of the controls developed in this article are:

  • Provide easy integration with existing Web applications. The controls should encapsulate all logic and JavaScript code to simplify the deployment process.

  • Be configurable.

  • Minimize data- and page-size overhead.

  • Leverage CSS and HTML standards.

  • Provide cross-browser support (Microsoft® Internet Explorer, Mozilla Firefox).

  • Leverage common design patterns/best practices to improve code maintainability...

[Read More..]

Courtesy: Ibm.com