0
var text,replacing$;
$.get('reload.html,function(response){
text=response;
});
replacing$=$(text).find('td')
alert(replacing$.get())
当我尝试使用替换$ .get()时,它只是空的。从ajax失败获取元素
这里的reload.html(注意真的,只是把它备案)
<tr>
<td>
LOADED First
</td>
</tr>
其驾驶我疯狂。响应文本在回调函数内工作得很好,但从不在外
$ .get是异步的 –
欢迎接受/ upvote最合适的答案。 http://meta.stackexchange.com/questions/5234/how-does-accepting-an-answer-work –