[整]JQuery方法汇集

1、$("...").load(url, data, function(response, status, xhr))

参数:

url: 规定要将请求发送到哪个 URL。

data: 可选。规定连同请求发送到服务器的数据。

function(response,status,xhr):  可选。规定当请求完成时运行的函数。

  额外的参数: response - 包含来自请求的结果数据

         status - 包含请求的状态("success", "notmodified", "error", "timeout" 或 "parsererror")

         xhr - 包含 XMLHttpRequest 对象

例子

$("#result").load("ajax/test.html");
$("#result").load("ajax/test.html", function() { alert("Load was performed."); });
$("#result").load("ajax/test.html #container");//(加载代码片段)

详细介绍地址http://www.w3school.com.cn/jquery/ajax_load.asp

原文地址:https://www.cnblogs.com/zongchenjie/p/2738801.html