title: Requirements of AJAX
body: <p>Ok, so I understand what AJAX is. However, my problem is understanding what is required for it to run. For example, I have written three files that do a simple load a file when a button is pressed. Although this is not exactly AJAX with the whole XMLHTTP Request code (maybe I'm confused and this isn't AJAX at all), it doesn't work. My first question is what am I missing? Second, I read about how AJAX requires for the files to be in another server for it to work. Can anyone point to an article, tutorial, or even an explanation about this. </p>
  
  <p>First File Code (This contains the button)</p>
  
  <pre><code>&lt;!doctype html&gt;
  &lt;html lang="en"&gt;
  &lt;head&gt;
  &lt;meta charset="utf-8"&gt;      
  &lt;/head&gt;
  
  &lt;body&gt;
  &lt;input type="button" value="load" /&gt;
  &lt;div id="content"&gt;&lt;/div&gt;
  &lt;script src="http://code.jquery.com/jquery-latest.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="ajax.js" &gt;
  &lt;/script&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Second file that contains the file that I want to load when the button is pressed.</p>
  
  <pre><code>&lt;strong&gt;This has been loaded into another page!&lt;/strong&gt;
  </code></pre>
  
  <p>Third file contains the sudo-AJAX call.</p>
  
  <pre><code>$('#button').click(function () {
  $('#content').load('test_ajax_return.php'); 
      });
  </code></pre>