上的“访问被拒绝”错误在以下ajax代码我得到一个“访问被拒绝”错误消息。可以帮助我在这方面的人。ajax
<html>
<head>
<script type="text/javascript">
function a()
{
var xmlhttp=new XMLHttpRequest();
xmlhttp.open("GET","load1.txt",true);
xmlhttp.onreadystatechange=function()
{
document.getElementById("hello").innerHTML=xmlhttp.requestText;
}
}
</script>
</head>
<body>
<input type="button" value="hello" onclick="a()"/>
<div id="hello"></div>
</body>
</html>
的活生生的例子作为错误说乌尔否认访问该特定文件..检查您是否有权访问load1.txt – Vijay 2011-04-28 09:34:29
是的,我有读取写入权限。:-) – 2011-04-28 09:37:01