$(".selector").validate({ invalidHandler: function(form, validator) { var errors = validator.numberOfInvalids(); if (errors) { //resize code goes here } } })