Introduction Of AJAX -:
AJAX is Based on Open Standards - :
AJAX is based on following open standards -
1. Browser-based presentation with the help of HTML and Cascading Style Sheets (CSS).
2. Data gets stored in XML format, fetched from server.
3. Data is fetches using XMLHttpRequest objects in the browser behind-the-scenes.
Some Other Tools for Designing -:
1. Loosely typed scripting language.
3. Glue for the whole Ajax operation.
1. API for accessing and manipulating structured documents.
2. This helps to Represents the structure of XML and HTML documents.
Some Steps Of AJAX Operation -:
1. A client event occurs.
2. An XMLHttpRequest object is created.
3. The XMLHttpRequest object is configured.
4. The XMLHttpRequest objects make an asynchronous request to the Web server.
5. The Web server returns the result containing XML.
6. The XMLHttpRequest calls the callback() function and processes the result.
7. The HTML DOM is Updated.
Benefits of AJAX -:
1.Callbacks: Ajax is used to perform a callback, making a quick round trip to and from the server to retrieve and/or save data without posting the entire page back to the server. By not performing a full postback and sending all data to the server, network utilization is minimized and quicker operations occur. In sites and locations with restricted bandwidth, this helps to improve network performance. Most of the time, the data being sent to and from the server is negotiable. With the help of callbacks, the server is not required to process all form elements. Due to sending only the necessary data, there is limited processing on the server. So no need to process all form elements, process the ViewState, send images back to the client, or send a full page back to the client.
2. Making Asynchronous Calls: This Concept allows you to make asynchronous calls to a web server. Through this, It helps the client browser to avoid waiting for all data to arrive before allowing the user to act once more.?
3. User-Friendly: Due to page postback is being eliminated, Ajax-enabled applications will always be more responsive, faster and more user-friendly.
4. Faster: The main purpose of Ajax is to improve the speed, performance, and usability of a web application. Let's take an Example of Ajax is the movie rating feature on Netflix. The user rates a movie and these will be saved to their database without waiting for the page to refresh or reload. These ratings are being saved to their database without posting the entire page back to the server.