标签:
Javascript
<script type="text/javascript"> function btnClick() { var xmlhttp = new ActiveXObject("Microsoft.xmlhttp"); if(!xmlhttp) { alert("创建对象异常"); return false; } xmlhttp.open("POST", "XXXX", false); xmlhttp.onreadystatechange = function() { if (xmlhttp.readystate == 4) if(xmlhttp.status == 200) alert (xmlhttp.responseText); document.getElementById("Text1").value=xmlhttp.responseText; } else { alert ("Ajax 服务器错误"); } } } xmlhttp.send(); </script>
标签:
原文地址:http://www.cnblogs.com/TikyZheng/p/4644219.html