$("#form_id").submit(function(e) {
var form = $(this).get(0),
submitted = false;
function submit_form() {
if (!submitted) {
document.createElement('form').submit.call(form);
submitted = true;
}
}
mpq.track("Form submitted", {
name: $(this).find(".name").val(),
email: $(this).find(".email").val()
}, submit_form);
// set a timeout just in case our tracking call takes too long
setTimeout(submit_form, 500);
e.returnValue = false;
if (e.preventDefault !== undefined) { e.preventDefault(); }
});