Enabling close pop up similar to markers in Google maps
<p>I think my problem is fairly simple, however I am unable to figure it out. I want to close a note pop up with an "x" icon/div in the top right corner of the note. </p>

<p>Currently I have this as the code. The only solution to minimize the note is to double click on it, which obviously isn't a viable solution.</p>

<pre><code>$('.note').click(function (event) {
  $(this).find('.notepopup').show();                                      
});

$('.note').dblclick(function (event) {
  $(this).find('.notepopup').hide();
});
</code></pre>

<p>I tried changing the second part to target the '.close' div, like this:</p>

<pre><code>$('.close').click(function (event)  {
  $(this).find('.notepopup').hide();
});
</code></pre>

<p>I am beginning to think it has something to do with the relationship between .close and .notepopup - as in - .close is within the popup, whereas .note is in a sense the parent element of .notepopup</p>

<p>Any help would be great. If you really want to get crazy, you can look at what I'm working on: <a href="http://www.scottefloyd.com/notewebapp/demo.php" rel="nofollow">http://www.scottefloyd.com/notewebapp/demo.php</a></p>
