1. jquery ajax开发介绍
jquery的ajax总共包括6种
$.ajax(url,[settings])
load(url,[data],[callback])
$.get(url,[data],[fn],[type])
$.getJSON(url,[data],[fn],[type])
$.getScript(url,[callback])
$.post(url,[data],[fn],[type])
1.$.ajax()它是jquery提供的最基本的ajax编程方式。它的功能比较强大,但是使用比较麻烦,一般不使用,它是将远程数据加载到XMLHttpRequest对象中。
2.load get post 它们简化了$.ajax操作,get post针对get与post请求的,它们是开发中使用的比较多。
3.getScript getJSON 它们是用于解决ajax跨域问题的。
Ajax的优点:使用ajax可以实现页面的部分更新
使用ajax开发的web,可以让用户感受更好,更快
Ajax核心(引擎):XMLHTTPRequest