Explanation of the difference between Ajax submission and traditional form submission

  • 2020-03-30 01:39:16
  • OfStack

1. Why AJAX?
With AJAX, the user experience of the Web will be more "agile" : the data submission page will not flash; Page local update speed is fast; Low network bandwidth usage.

2. The simplicity of AJAX development compared to the traditional mode:
In traditional mode, form submission redraws the entire page, requiring a lot more code to keep the page user from changing the form's state. More parameters are passed between the controller and the template to keep the page in state. AJAX, on the other hand, doesn't care about or affect the rest of the page because the page is only partially updated.

3. The difficulty of AJAX development compared with the traditional mode:
You need to know and be proficient in JavaScript, which has a lot of hurdles like debugging and browser compatibility.

= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =

There are several differences:  
1. Ajax in the submission, request, receive, are asynchronous, the page does not need to refresh; Form submission is to create a new page, even if it is submitted to its own page, also need to refresh;

2. When A submits, it creates A new request in the background; F is to abandon this page, and then request;

3. A must be implemented using JS. The operation cannot be completed without JS enabled browser. F is the instinct of the browser, whether or not to open JS, you can submit the form; 4. When A submits, requests and receives, the whole process needs to use programs to process its data; When F submits, it is automatically completed according to your form structure without any code intervention.

Related articles: