What is AJAX?

AJAX stands for Asynchronous JavaScript and XML. AJAX is not a new technology; it is a new way of combining existing technologies. What we do in AJAX is create an asynchronous request to the web server using client-side JavaScript and an XmlHttpRequest object, and map a function to be executed when the response is received. An asynchronous request means that the browser does not need to wait for the response after sending the request to the server. What we gain using AJAX is a responsive user interface, and we get this by sending a request to the web server for a small amount of information, as many times as we want, without sending the complete information on the form. In AJAX, the request is for data, not for a GUI element, so an AJAX request can be handled by an ASP.NET page without any HTML content, a custom HTTP module, or a web service. The core component in AJAX is the XMLHTTPRequest object. As many web developers are not familiar with this object, we will discuss it in detail in the next section. Following are the advantages and disadvantages of AJAX.


1. The use of AJAX the increases the richness and responsiveness of the web page interface.
2. It reduces the network traffic and CPU usage on web server. This is because there will be no post back to the server that will render a complete HTML page. For example, if you are displaying a lot of data in a web page, the HTML page size may be about 100 kilobytes. This big string has to be created on the server and then sent back to the client.


The use of AJAX requires users to have JavaScript enabled on their browser. Because of this, an AJAX website should provide a non-AJAX alternative for users without JavaScript enabled.
AJAX breaks the normal browsers’ Back button behavior. When a page is updated dynamically, returning to the previous state may not be possible, since browsers typically record only complete page requests in their history lists.
As not all browsers are complying with W3C standards, AJAX applications have to be tested rigorously to deal with the quirks of different browsers.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s