There are many development environments or editors that can be used to learn Ajax, and individuals use Google Chrome and sublime for beginners. Here are a few points to note when you are beginners:
We generally use Ajax in the jquery library directly, so be sure to introduce it in the head.
When debugging an AJAX content, do not open it directly in the browser, but should be tested on the server, such as:
650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M01/86/1C/wKioL1e1LqCieSPTAABNOEnGP5k061.png-wh_500x0-wm_3 -wmp_4-s_1898866834.png "style=" Float:none; "title=" 2.png "alt=" Wkiol1e1lqciesptaabnoengp5k061.png-wh_50 "/>
650) this.width=650; "Src=" Http://s4.51cto.com/wyfs02/M02/86/1C/wKioL1e1LqPgG9hLAABVM_jePwQ930.png-wh_500x0-wm_3 -wmp_4-s_2157271883.png "style=" Float:none; "title=" 1.png "alt=" Wkiol1e1lqpgg9hlaabvm_jepwq930.png-wh_50 "/>
If an AJAX error occurs and does not perform as expected, we need to step through the steps and try to change the way you read the file into text plain text.
$ (". Send_ajax_request"). Click (function () {//Send Ajax request $.ajax ({URL: "People.txt", type: "Get", DataType: "Text",//data: {ID=SS&NAME=SS} is used to send data success:function (data) {//Here first try alert out data},error:function () {alert ("error");});});
If this step can be implemented, it proves that the Ajax file was written incorrectly and began to modify the original. json file. Here, the cloud is recommended that you can use the English input method to write the approximate framework of the JSON file and then write.
This article is from the "11817362" blog, please be sure to keep this source http://11827362.blog.51cto.com/11817362/1839877
Introduction to Ajax Learning Tips