title: undefined message when trying to get attr id value
body: <p>All,</p>
  
  <p>This is simple but can't seem to figure this out.  I have a close function that should display out the value of the attribute id.  But I get a message of undefined in my alert message.  Thanks for any help.</p>
  
  <p>href code:</p>
  
  <pre><code>     &lt;a href="javascript:close()"&gt;
         &lt;img class="close-icon" alt="" /&gt;
       &lt;/a&gt;
  </code></pre>
  
  <p>function:</p>
  
  <pre><code>    function close() {
          var currentID = $(this).attr('id');
          alert('ID clicked on: ' + $(this).attr('id'));
       }
  </code></pre>
  
  <p>Thanks for any help.</p>