I have a form in a modal, when the users clicks submit, thea form will be validated, if its contain errors, it will not be submitted, so the user can click on modal close button or anywhere to close the modal or hide it, then if the user re-open the modal, the validations css will be remains in the form as they was before, so the question is how I can reset the form to be displayed as a clear fom without any validation css, here is a code I used, but didn't worked:
$('#newsletterModal').on('hidden.bs.modal', function () {
$('#newsletter')[0].reset();
$('#newsletter')
.bootstrapValidator('disableSubmitButtons', false) // Enable the submit buttons
.bootstrapValidator('resetForm', true);
});