title: click on link should not trigger parental onclick-event
body: <p>I've got the following code:</p>
  
  <pre><code>&lt;div onclick="alert('div event');" style="cursor:pointer"&gt;
      some text
      &lt;a href="asd.php" id="link"&gt;click&lt;/a&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>When somebody clicks on the link the javaschipt event is triggered. I want that the event is only triggers if somebody clicks on the text or on the empty space inside the div container; and not if somebody clicks on the link.</p>
  
  <p>Is it possible to call a function when the event is triggered, which checks on which elements the user has clicked. something link</p>
  
  <pre><code>onclick="foo(caller);"
  </code></pre>
  
  <p>and</p>
  
  <pre><code>function foo(element){
      if(element!='link'){
          alert('yes');   
      }
  } 
  </code></pre>