摘要:
1 //1.创建Ajax对象,已经封装好的函数: 2 function createXHR(){ 3 if (typeof XMLHttpRequest != "undefined"){ 4 return new XMLHttpRequest(); 5 } else if (typeof ActiveXObject != "undefined"){ 6... 阅读全文
摘要:
1 xhr.onreadystatechange = function(){ 2 if (xhr.readyState == 4){ 3 if ((xhr.status >= 200 && xhr.status < 300) || xhr.status == 304){ 4 alert(xhr... 阅读全文