title: Jquery open a popup and nest it into the clicked div
body: <p>I want to open a popup and nest it into a div. I'm using <strong>appendTo</strong>. 
  my popup has to be open inside the clicked div. <strong>parent</strong>?</p>
  
  <p>then append some html.
  what I'm missing?</p>
  
  <p>fiddle:
  <a href="http://jsfiddle.net/XeELs/151/" rel="nofollow">http://jsfiddle.net/XeELs/151/</a></p>
  
  <pre><code> if ($("#events .event").hasClass("selected")) {
              $('.popup-event').parent().appendTo($(".event"));
              $(this).fadeIn();
              $('.popup-event').append('&lt;span class="close-popup-event" /&gt;'); 
          }else{
              $('.close-popup-event').fadeOut('');
         }
  </code></pre>
  
  <p><strong>HTML</strong></p>
  
  <pre><code>&lt;div class="event"&gt;
  &lt;/div&gt;
  
  
  
  &lt;aside class="popup-event"&gt;
  
  &lt;/aside&gt;
  </code></pre>