Ajax advantages and disadvantages

Source: Internet
Author: User
The biggest advantage of AJAX is that data can be maintained without updating the entire page. This allows web applications to respond quickly to user actions and avoid sending unchanged information on the network.
Ajax does not require any browser plug-ins, but users need to allow JavaScript to be executed on the browser. As with DHTML applications, Ajax applications must undergo rigorous tests on various browsers and platforms. With the maturity of Ajax, some libraries that simplify Ajax usage have also been released. Similarly, there has also been another helper programming technology that provides alternative functionality for users who do not support JavaScript.
The main criticism for Ajax application is that it may damage the normal behavior of the browser's back button [4]. When a page is dynamically updated, the user cannot return to the status of the previous page, because the browser can only write down the static page in the history. The difference between a fully read page and a dynamically modified page is very subtle. users usually want to click the back button to cancel their previous operation, however, this is not possible in Ajax applications. However, developers have come up with various solutions to solve this problem. Most of them create or use a hidden IFRAME to reproduce the changes on the page when the user clicks the back button to access the history. (For example, when a user clicks back in Google Maps, it searches in a hidden IFRAME and then reflects the search result to the Ajax element, to restore the application status to the current state .)
According to a related opinion, using dynamic page update makes it difficult for users to save a specific State to favorites. The solution to this problem has also appeared. Most of them use the URL snippet identifier (usually called the anchor, that is, the # part following the URL) to keep track, allows the user to return to the status of a specified application. (Many browsers allow JavaScript to dynamically update the anchor, which allows Ajax applications to update the anchor while updating the display content .) These solutions also address a lot of arguments about not supporting the back button.
During Ajax development, network latency-that is, the interval between the user sends a request to the server for response-requires careful consideration. If you do not explicitly respond to [5], do not properly preread data [6], or improperly process XMLHttpRequest [7], the user will be delayed, this is what users do not want to see and what they cannot understand [8]. The common solution is to use a visual component to tell the user that the system is performing background operations and reading data and content.
Some handheld devices (such as mobile phones and PDAs) cannot support Ajax yet;
The javascript-based Ajax engine makes JavaScript compatibility and debugging a headache;
Ajax does not need to refresh new loads. Because the page changes are not as obvious as the refresh overload, it is easy for users to be troubled-users do not know whether the current data is new or updated; existing solutions include: relevant location prompts, data update areas are designed to be obvious, and prompt users after data update;
The support for string streaming media is not as good as flash and Java Applet;
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.