ajax自动刷新页面问题
<script language= "javascript ">
var XMLHttpReq;
function createXMLHttpRequest() {
if(window.XMLHttpRequest) {
XMLHttpReq = new XMLHttpRequest();
}
else if (window.ActiveXObject) {
try {
XMLHttpReq = new ActiveXObject( "Msxml2.XMLHTTP ");
} catch(e){
try {
XMLHttpReq = new ActiveXObject( "Microsoft.XMLHTTP ");
} catch (e) {}
}
}
}
function sendRequest() {
createXMLHttpRequest();
var url = "cpuconfig.do ";
XMLHttpReq.open( "GET ", url, true);
XMLHttpReq.onreadystatechange = processResponse;
XMLHttpReq.send(null);
}
function processResponse() {
if (XMLHttpReq.readyState == 4) {
if (XMLHttpReq.status == 200) {
setTimeout( "sendRequest() ", 5000);
} else {