title: Trigger click() for dynamically created elements
body: <p>Ok, there are a couple approaches to the problem of triggering a click() for a dynamically-generated element. First, this will work for Chrome but not IE or FF: </p>
  
  <pre><code>var href="/myUrl";
  var link = $("&lt;a&gt;");
  link.prop("href", href);
  link[0].click()
  </code></pre>
  
  <p>So, if the thinking is that using click() on an element that doesn't exist won't work in IE or FF, what's the best approach? </p>
  
  <pre><code>var href="/myUrl";
  var link = $("&lt;a&gt;");
  link.prop("href", href);
  $(document).append(link); // Attach it to the DOM so it exists
  link[0].click()
  </code></pre>
  
  <p>Or is there something even simpler that I'm missing? Thanks for any helpful tips. </p>