title: jQuery on() and stopPropagation()
body: <p>I have a side pane that slides in from the left, adding content dynamically with get(). I want all clicks outside the pane to cause it to close by triggering a function. Based on other questions I read, I came up with the following code.</p>
  
  <pre><code>$('html').click(function() {
      if (side_showing) {
          close_side();
      }
  });
  
  $(document).on("click", "#side", function(event) {  
      event.stopPropagation();
  });
  </code></pre>
  
  <p>I can't seem to make it work. I know that the <code>on()</code> function is being triggered, but <code>event.stopPropagation</code> doesn't seem to be. Any tips?</p>