Skip to content

Instantly share code, notes, and snippets.

@StevenLangbroek
Created September 26, 2012 14:01
Show Gist options
  • Save StevenLangbroek/3788238 to your computer and use it in GitHub Desktop.
Save StevenLangbroek/3788238 to your computer and use it in GitHub Desktop.
validationEngine ajax-handler
$(document).ready(function(){
$('#myForm').validationEngine('attach', {
onValidationComplete: function(form, status){
if(status){ // als ie validate
var url = form.attr('action'),
data = form.serialize(),
message = '<p>Hier het bedankt bericht</p>';
$.post(url, data, function(results){
form.load('/die_template_dus'); // of form.html($(results)); als je de return in je formulier wilt plaatsen.
});
}
}
})
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment