title: Jquery: Stop propagation?
body: <p>I have added stopPropagation, however, I still get two popups in a row. This is better than before, where there were 20 popups for one element that is clicked....is there a better approach or am I missing something ?</p>
  
  <pre><code>$(top.document).ready(function () {
  
      $("*").click(processAction);
  
  });
  
  function processAction(e) {
      var clicked = e.target;
      e.stopPropagation();
      alert(clicked.tagName);
      e.stopPropagation();
      switch (clicked) {
      case "A":
          //execute code block 1
          break;
      case "INPUT":
          //execute code block 2
          break;
      default:
          //code to be executed if n is different from case 1 and 2
      }
  };
  </code></pre>