title: Counting the number of elements with the same class in jquery
body: <p>How do I count dynamically generate elements with the same class in jquery?
  I found a similar question, but unfortunately it didn't work.
  <a href="https://stackoverflow.com/questions/2727303/jquery-counting-elements-by-class-what-is-the-best-way-to-implement-this">jQuery counting elements by class; what is the best way to implement this?</a></p>
  
  <p>I did something like this which I based from the answers:</p>
  
  <pre><code>$('.capital_class').live('blur', function(){
  
  alert($(this).length);
  });
  </code></pre>
  
  <p>The elements with a class of capital_class are dynamically generated. But I always get the length of 1, whenever I blur. How do I get this correctly?</p>