title: jQuery - Get title attribute using each
body: <p>I have this jquery code:</p>
  
  <pre><code>$.each('.button.gobutton', function() {
        alert($(this).attr('title'));
   });
  </code></pre>
  
  <p>I basically want to iterate through each element and get the value of the title for each element. However when I run this code I get undefined for all the values. Below is the html:</p>
  
  <pre><code>&lt;button class="button gobutton" title="2"&gt;GO&lt;/button&gt;
  </code></pre>