Reputation: 9332
I have the code below:
$('form', dialog).submit(function () {
...
Then every form submitted is intercepted.
My question: how can I stop this interception?
Thanks.
Upvotes: 0
Views: 82
Reputation: 84
You need to add return false;
in the end of your function like this:
function(){
/* Some code */
return false;
}
Upvotes: 0
Reputation: 1058
you can use this:
$('form', dialog).submit(function (e) {
e.preventDefault();
}
event.preventDefault()
If this method is called, the default action of the event will not be triggered.
or you can simply use:
$('form', dialog).submit(function (e) {
//your code here
return false;
}
Upvotes: 0
Reputation: 2236
According to the docs, try adding return true;
at the end of your function.
Upvotes: 0
Reputation: 78650
unbind should do the trick.
$('form', dialog).unbind("submit");
Upvotes: 1