title: Reading a txt file from Server, writing it to website
body: <p>Here's my problem.</p>
  
  <p>1) I'm wanting to create a txt file (or possibly a html file) to hold a paragraph of information to be written onto a  when a user clicks a word. It's part of a game I am working on.
  </p>
  
  <p>If you go to www.w3schools.com and go to their "try it" editor they have...</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
  &lt;script&gt;
  function loadXMLDoc()
  {
  var xmlhttp = XMLHttpRequest();
  xmlhttp.onreadystatechange=function()
  {
  if (xmlhttp.readyState==4 &amp;&amp; xmlhttp.status==200)
  {
  p = document.createElement("p");
  p.innerHTML=xmlhttp.responseText;
  document.getElementById("story").appendChild(p);
  }
  }
  xmlhttp.open("GET","ajax_info.txt",true);
  xmlhttp.send();
  }
  &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
  
  &lt;div id="story"&gt;&lt;h2&gt;Let AJAX &lt;i onclick=loadXMLDoc()&gt;change&lt;/i&gt; this text&lt;/h2&gt;&lt;/div&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>This is exactly what I want my program to do (not the actual words of course) but I'm running html with an external .js sheet. Should I store my ajax somewhere else? Or, should my .txt file look different than just a bunch of words in it? I'm completely confused.</p>
  
  <p>The fun part will be once this actually starts working, I'm going to have to implement an "onclick" event with italics inside of the txt file.</p>
  
  <p>If there is a better way to do this then appendChild(p.innerHTML("lfjhdfh")) and AJAX please let me know asap. I have a total of 11 weeks to get this thing working for a school project LOL.</p>