这段代码,Ajax的功能无法实现

(getNewContent.js)
function getNewContent(){
var request = getHTTPObject();
if(request){
request.open("GET","example.TXT",true);
request.onreadystatechange = function(){
if(request.readyState==4){
var para = document.createElement("p");
var txt = document.createTextNode(request.responseText);
para.appendChild(txt);
document.getElementById("new").appendChild(para);
}
};
request.send(null);
}else{
alert("Sorry,your browser doesn't support XMLHttpRequest");
}
}
addLoadEvent(getNewContent);
(getHTTPObject.js)
function getHTTPObject(){
if(typeof XMLHttpRequest == "undefined")
XMLHttpRequest = function (){
try {return new ActiveXObject("Msxml2.XMLHTTP.6.0");}
catch (e) { }
try {return new ActiveXObject("Msxml2.XMLHTTP.3.0");}
catch (e) { }
try {return new ActiveXObject("Msxml2.XMLHTTP");}
catch (e) { }
return false;
}
return new XMLHttpRequest();
}
(addLoadEvent.js)
function addLoadEvent(func){
var oldFun = window.onload;
if(typeof window.onload != 'function')
{
window.onload=func;
}else{
window.onload = function(){
oldFun();
func();
}
}
}
窝把这三个js文件,用script加到html文件里,exmaple.txt,文档里面的文字没有显示在id为new的div里面,求大神帮忙,代码哪里出了问题。

3个js文件确认都正确导入没有?是否发布网站了网站通过http协议访问,而不是本地file,本地file不要使用IE或者chrome,不允许请求本地资源(IE入如果是Acx创建可以,XMLHttpRequest不行)