不知道是不是你想要的效果 第一种,这个是在加载完之后自己处理response中的文字(不过其实也可以直接处理已经加载到页面上的那些html而不理会这个response对象) $('your_target').load("your_html_url.html", function(response, status, xhr) { if (status == 'success') { var anchorLists = $(response).find('a'); console.log(anchorLists); } }); 第二种,有选择性的加载目标页中的内容,这个例子只会加载目标页面的img对象 $('your_target').load("your_html_url.html img");
不知道是不是你想要的效果
第一种,这个是在加载完之后自己处理response中的文字(不过其实也可以直接处理已经加载到页面上的那些html而不理会这个response对象)
第二种,有选择性的加载目标页中的内容,这个例子只会加载目标页面的img对象