ajax问题(急求助)
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%><%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<title>提取index.jsp的数据</title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<!--
<link rel="stylesheet" type="text/css" href="styles.css">
-->
<style type='text/css'>
* { font-family: Tahoma, Arial, sans-serif; }
#divId{ color: #48f; }
</style>
<script type="text/javascript">
var XMLHttpReq;
function createXMLHttpRequest(){
if(window.XMLHttpRequest)
XMLHttpReq = new XMLHttpRequest();
else if(wondow.ActiveXObject)
XMLHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
}
function chuli(){
if(XMLHttpReq.readyState == 4){
if(XMLHttpReq.status == 200 || XMLHttpReq.status == 0){
var divInfo = document.getElementById("divId");
if(responseDataType != "Text")
divInfo.innerHTML = XMLHttpReq.responseXML;
else
divInfo.innerHTML = XMLHttpReq.responseText;
}else{
window.alert("你所请求的页面有异常");
}
}
}
function lianjie(){
var url="index.jsp";
createXMLHttpRequest();
XMLHttpReq.onreadystatechange = chuli;
XMLHttpReq.open("GET",url,true);
XMLHttpReq.send(null);
}
</script>
<!--
<script type="text/javascript" src="prototype.js"/>
<script type="text/javascript">
window.onload=function(){
new Ajax.Request(
"index.jsp",
{
method:"post",
onComplete:function(xhr){
$('divId').innerHTML = xhr.responseText;
}
}
);
} ;
</script>
-->
</head>
<body onLoad=lianjie();>
<div id="divId">
</div>
</body>
</html>
index.jsp页面里有数据
可是我的这个页面取不到数据是什么原因啊