コンピューターから Web サイトにテキスト ファイルを読み込もうとしています。IE では動作していますが、Chrome では動作しないようです。私はhtmlにまったく熟練していないので、どんな支援も素晴らしいでしょう!
<html>
<body>
<div id = "content">
</div>
<script lang = "javascript">
if (window.XMLHttpRequest)
{
xhttp=new XMLHttpRequest();
}
else // Internet Explorer 5/6
{
xhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xhttp.open("GET","./Test.txt",false);
xhttp.send("");
xmlDoc=xhttp.responseText;
document.getElementById('content').innerHTML = xmlDoc;
</script>
</body>
</html>