目前只能同一个文件夹的啊~
var xmlhttp;
if (window.XMLHttpRequest){// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else{// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.onreadystatechange=function() {
if (xmlhttp.readyState==4 && xmlhttp.status==200){
if(xmlhttp.responseText==1){
document.getElementById("myForm").submit();
}
else{
document.getElementById("login_note_area").innerHTML="帐号或密码不对";
}
}
};
var array=document.getElementById("id").value.toString();//id
array+=":";
array+=document.getElementById("password").value.toString();//密码
xmlhttp.open("POST","login.php?q="+array,true);
xmlhttp.send();
login.php和js在不同文件夹怎么访问啊