I'm trying to use jQuery SimpleModal Confirm to show a Yes/No confirmation when a form is submitted.
I had modified the demo here (last in list), as follows, to catch and block the form submission.
However, this only seems to work with jQuery 1.2.6 a recent upgrade to 1.3.2 stops the form from being submitted if yes is clicked.
I can't however, work out what in my code is now wrong / incompatible. The demo (which is a simple window.href implementation works in both versions).
$(document).ready(function () {
$('input.delete').click(function (e) {
e.preventDefault();
var target = $(e.target);
confirm("Really delete this event?", function () {
target.click()
});
});
});