title: AJAX live update a PHP page with a new echo output
body: <p>I'm currently working on an insurance website, and really anything other than CSS and HTML is a bit over my head. I just recently figured out how to make variable links that spit out different echo statements. Here's an example of an original page: <a href="http://www.mmisi.com/autoquote.php" rel="nofollow">http://www.mmisi.com/autoquote.php</a> and here's one with a variable link: <a href="http://www.mmisi.com/autoquote.php?discount=safedriver" rel="nofollow">http://www.mmisi.com/autoquote.php?discount=safedriver</a></p>
  
  <p>What I'm trying to do is employ this similar feature while using AJAX (well, I presume AJAX is what I need) in order to update a live page after clicking on a link without having to reload the page.</p>
  
  <p>So, what I would like to be able to do, is have a viewer be on autoquote.php, and click a link for autoquote.php?discount=safedriver. Instead of the link loading a completely new page, it would just spit out the appropriate echo statement on the fly.</p>
  
  <p>Here's the PHP I currently have:</p>
  
  <pre><code>$discount = $_GET['discount'];
  
  if ( $discount == "safedriver" ) { echo "Ask about a safe driver discount, which could save you up to 25% for drivers with no violations or at-fault accidents!"; }
  </code></pre>