Event managment: Replace click event
<p>I have a button with a click event (from a 3. party library) which submits a form. I like to remove the click event, add my own function and call the original event after a validation.</p>

<p>I thought i just add an <code>event.stopImmediatePropagation();</code> but that did not work. Maybe because of the order the events where added(?).</p>

<p>Is the another way to manage the event execution?</p>

<p>Or how can I get the old event to do something like this:</p>

<pre><code>originalClickEvent = $('#button').doSomeMagicAndGetTheEvent('click');
$('#button').unbind();
$('#button').bind('click', function (event) {
  if (valid()) originalClickEvent();
});
</code></pre>
