How to cancel submit on AjaxForm
ajax, jquery, jquery-plugins
Solution
You can use `return false;` in `beforeSubmit` function to prevent form submission.
Source: http://jquery.malsup.com/form/#options-object
Problem
I'm working with a jQuery plugin (ajax form), I try to implement something like this: ``` $("#MyFormID").ajaxForm({ dataType: "json", resetForm: true, beforeSubmit: function() { //validateData returns boolean if (validateData()) { // continue submit } else { //cancel submit } }, success: function(json) { //show success notification } }); ``` is there a way to stop the ajax from submiting the form? on beeforesubmit function maybe?