标签:stat nbsp cti ajax txt class selector new function
<div class="cont"></div> <script> var ajx = new XMLHttpRequest() ajx.open("get","./info.txt",true) ajx.onreadystatechange = function(){ if(ajx.readyState!=4){ return; } if(ajx.status>=200 && ajx.status<300){ document.querySelector(‘.cont‘).innerHTML = ajx.responseText } } ajx.send() </script>
标签:stat nbsp cti ajax txt class selector new function
原文地址:https://www.cnblogs.com/wangbingblog/p/11543811.html