Skip to main content

What is AJAX ?

Posted by arungupta on December 8, 2006 at 9:30 AM PST

This is a follow up blog from here.
It provides a brief description of the most prominent technology, AJAX, that
enable the principles of Web

AJAX stands for Asynchronous
JavaScript and XML. This term was first introduced
by Jesse James Garrett in February 2005. It
is a set of technologies used to develop interactive web applications without
requiring a complete page refresh. This is achieved by decoupling user's
interaction with the web application and the web application's interaction with
the server. The presentation control logic is embedded as JavaScript code
snippets in the web page and the bulk of data is kept on the server. Any request
from user to the web application that does not require a round trip to the
server, for example data validation and displaying a different view of the
pre-loaded data, is handled by this code. If data needs to be fetched from the
server then this intermediate code makes an asynchronous request to the server
without any interruption of user's interaction with the application. This allows
a clear separation between presentation logic and the underlying data.

AJAX achieves this using the combination of following set of technologies:

  • XHTML and CSS
    for presentation
  • DOM for
    accessing parts of the page that needs to be refreshed
  • XMLHttpRequest
    for asynchronous exchange with the server
  • XML, Text or HTML
    as the format for data exchange
  • JavaScript to bind
    all of these pieces together.

There are several Ajax
available that combines all these technologies together and ease
the rapid development of Ajax-based applications. These frameworks offer
JavaScript functions on the client-side to send request to the server and
processes the requests, searches for the data and transmits them to the browser
on the server-side. All of this done by hiding the differences between different
browser and JavaScript runtime environments.
has a survey of the most
popular AJAX frameworks
. These frameworks are getting richer and providing a
comprehensive set of libraries ranging from DOM manipulation to animation
framework to complicated layout widgets. However if there is a need to write
your own custom widget then you can consider following the JavaScript
recommendations for AJAX component writers
with the Java Platform
explains the anatomy of an AJAX interaction in detail
and has other useful resources on AJAX.

AJAX enables rich
internet applications
and is one of the most prominent technology to enable
principles of Web
. Read how Gmail, Google
and Google
use AJAX to provide a richer, faster and more usable interaction. In my
next blog entry, I'll talk about jMaki
and my experience of developing a Web application using the recently released jMaki
1.0 beta

Technorati: AJAX Sun
Web 2.0

Related Topics >>