title: Setting on click action for dynamically generated links
body: <p>I have div of links that get dynamically generated.  I am trying to set the on click action of the links but it is not working.</p>
  
  <p>Code:</p>
  
  <pre><code>$('#tags').on('click', 'a', function(event) {
      event.preventDefault();
      $("#content").html("hello");
  });
  </code></pre>
  
  <p>The links in the tags div are generated by the following code:</p>
  
  <pre><code>$("#alpha_menu li").each(function() {
      $("#alpha_menu li a").click(function(event) {
          event.preventDefault();
          $.post('tags_script.php', {id: $(this).text()}, function(data) {
              $("#tags").html(data);
          });
      });
  });
  </code></pre>