CreateXMLHttp适应IE7

function CreateXMLHttp()

{

  var xmlhttp=null;

  if (window.ActiveXObject)

  {  

    xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");  

  } 

   else if (window.XMLHttpRequest)

  {   

    xmlhttp = new XMLHttpRequest();  

   }

  return xmlhttp;

}

posted @ 2011-04-08 11:24  南阳·源  阅读(924)  评论(0编辑  收藏  举报