Just want to have a partial Save function on my page.
so when a user clicks on Save for Later, no validation is performed. While a click on Save and Submit will trigger the validation before the form is submitted.
The buttons are:
<button type="submit" name="Action" value="SaveForLater">Save for Later</button>
<button type="submit" name="Action" value="SaveAndSubmit">Save and Submit</button>
I have the validate()
function in place already.
$('#formEdit').validate({
rules: ..,
messages: ...,
ignore: ...,
});
How can I by pass validate
when Save for Later is clicked?