new ActiveXObject('Microsoft.XMLHTTP');的问题改成new ActiveXObject("Msxml2.XMLHTTP");就OK了,晕菜,M$的兼容性。附录 我手上另外一个没问题ajax生成的代码。
var XMLHttpRequest = function()
{
var request = null;
try
{
request = new ActiveXObject('Msxml2.XMLHTTP');
}
catch(e)
{
try
{
request = new ActiveXObject('Microsoft.XMLHTTP');
}
catch(ee)
{}
}
return request;
}