Are you using Ajax today? -- Some common problems solved by Ajax applications

Source: Internet
Author: User
Are you using Ajax today?
-- Some common problems solved by Ajax applications

It is undeniable that I am very optimistic about Ajax technology. I think Ajax technology is just like HTML for the Internet. However, we must also see that AJAX technology cannot completely replace our conventional web development technology. Ajax technology has the advantages of eye-catching and many weaknesses. As developers, we cannot use Ajax in Web development because of the good Ajax technology.
By the way, Ajax cannot be used for Ajax. Just like steel needs to use cutting edge, Ajax should be used to make full use of its advantages. Most of the time, we still need to use MVC to implement the struts development framework as usual.
When it comes to Ajax, we can't help but mention another word highlighted with it: user experience. Ajax enriches the presentation layer of the B/S mode. For the UI of the B/S mode, it claims that it cannot be done, but cannot be imagined. This is a problem of user experience. Ajax is called refreshing. In fact, many times, users need to refresh to know that pages are submitted. For example, when saving data, using Ajax at this time is harmful to the user experience.
When can Ajax be used? First, the request is submitted to display the page data. At this time, users generally do not want to see the page refresh, which is the best time to use Ajax. 2. If the user can feel the submitted results from the page after the request is submitted, it is recommended that you do not refresh the page at this time. Ajax technology is recommended. Third, if the user cannot feel the submission action from the page after the request is submitted, such as adding and modifying data in most cases, page refreshing is required at this time, and Ajax technology cannot be used. Fourth, complex UI. Previously, for the complex C/S Mode UI, the B/S mode has always been an escape method. Now, you can use Ajax with confidence to solve the problem.
The practice of Ajax technology is like magic. Once you use it once, it will be easy. What are you waiting for in the face of the wonderful Ajax technology? Check whether your web application has any of the following problems. If so, try Ajax!
1. input value verification problems.
Input Validation is a common problem that can be solved in Js. However, you sometimes need to access the background, such as checking whether the user name is repeated when applying for a user. With Ajax, the page will not be refreshed.
2. Cascade display problems.
This problem should be the most frequently encountered problem in the performance layer, which often makes us difficult: You can access the background, the page needs to be refreshed, and the user experience is poor; if you use js to solve the problem, it is indeed a bit difficult for js to crash. If you use js to solve the problem, there will be a lot of code. If the data volume is large, there will be memory problems, and the data is not safe.
There are many such problems: The most common problems are two or more cascading selection boxes, deformation of the Selection box, cascading menu, navigation tree, and so on.
If you have encountered this type of problem, please act now! Using ajax to access the background requires no page refresh or excessive JS Code.
Third, the request result only changes some pages.
We often encounter this type of problem, for example, when the Forum replies to posts and the list of posts is on a page. These two UIS are on one page, and the user experience is better than replying to a post on another page. However, it is not good to refresh the entire page after the reply. As you can see, a large post list only adds one of your replies, but refreshes the entire page, from any perspective.
In terms of user experience and technology, Ajax is the best choice for this type of problem.
4. Use IFRAME for technical reasons.
IFRAME problems are purely caused by technical reasons. IFRAME has been introduced to solve technical problems, but the nested IFRAME has introduced other technical difficulties. Some try their best to solve this problem, while others simply do not use IFRAME. Without using IFRAME, The JS solution is cumbersome. Now you don't have to worry about it. Using ajax is the best solution.
Fifth, data entry and list are displayed on the same page.
In the C/S Mode UI, data entry and data list are usually displayed on the same interface, which provides a good user experience, the user input results are immediately displayed on the same interface. However, on the B/S UI, we often put data input and data display on two different pages due to the need to submit and refresh. Obviously, this user experience is certainly not as good as the C/S mode. There are still many problems like this. in B/S mode, other solutions are chosen for technical reasons. Now we can proudly use ajax to declare that we can make the same complex UI as the C/S mode.
Sixth, page turning.
If there is a technology that does not require refresh, would you like to try it? There are many such data display problems that need to be refreshed. Consider Ajax!

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.