跟大家講解下有關xml=new ActiveXObject("Microsoft.XMLHTTP")出錯_html/css_WEB-ITnose,相信小伙伴們對這個話題應該也很關注吧,現在就為小伙伴們說說xml=new ActiveXObject("Microsoft.XMLHTTP")出錯_html/css_WEB-ITnose,小編也收集到了有關xml=new ActiveXObject("Microsoft.XMLHTTP")出錯_html/css_WEB-ITnose的相關資料,希望大家看到了會喜歡。
我在寫一個js的腳本,我這么寫 xml=new ActiveXObject("Microsoft.XMLHTTP"); xml.open("GET","http://xxx/test.asp",false); xml.send(); 用firbug調試的時候這句直接跳過了為什么? 回復討論(解決方案)firbug ?firefox下要用 xml=new XMLHttpRequest(); if(window.XMLHttpRequest){ xml=new ActiveXObject("Microsoft.XMLHTTP");}else{ xml=new XMLHttpRequest();}xml.open("GET","http://xxx/test.asp",false);xml.send();
firbug ?firefox下要用 xml=new XMLHttpRequest(); if(window.XMLHttpRequest){ xml=new ActiveXObject("Microsoft.XMLHTTP");}else{ xml=new XMLHttpRequest();}xml.open("GET","http://xxx/test.asp",false);xml.send(); 這個對了,send怎么又出錯了? function GetLocalIPAdress(){if(window.ActiveXObject){xml=new ActiveXObject("Microsoft.XMLHTTP");}else{xml=new XMLHttpRequest();}xml.open("GET","http://iframe.ip138.com/ic.asp",false);xml.send(null);kk=xml.ResponseText;alert(kk);i=kk.indexOf("[");ie=kk.indexOf("]");ip=kk.substring(i+1,ie);alert(ip);return ip;}
iframe.ip138.com不是你的域,不能跨域的
iframe.ip138.com不是你的域,不能跨域的 那我怎么能請求這個ip地址呢?
iframe.ip138.com不是你的域,不能跨域的 那我怎么能請求這個ip地址呢?
來源:php中文網