首页  

XMLHttpRequest 例子     所属分类 javascript 浏览量 512

<body>
  <h2>XMLHttpRequestDemo</h2>
  <div id="msg"></div>
  <script>
    var xhttp = new XMLHttpRequest();
    xhttp.onreadystatechange = function () {
      if (this.readyState == 4 && this.status == 200) {
        // Typical action to be performed when the document is ready:
        document.getElementById("msg").innerHTML = xhttp.responseText;
      }
    };
    xhttp.open("GET", "/info", true);
    xhttp.send();
  </script>
</body>


上一篇     下一篇
jQuery 实用代码

使用 netcat 查看 http 请求信息

jquery ajax 实例

ssh端口转发

PostgreSQL DBA 常用SQL

temporal namespace 创建和更新关键代码