jquery - Contact Form 7 validation trigger event -
when user clicks on submit button contact form 7 form, want page scroll validation message section.
my approach:
i using jquery on click event submit button , on click scrolling page validation message section.
i sure not correct. because on click scrolls section message has not yet come through ajax.
so, there way create event when validation done in contact form 7 , use scroll down.
contact form 7 triggers wpcf7:invalid in case. can use trigger:
$(window).on('wpcf7:invalid', function() { // let's scroll }); source: https://github.com/wp-plugins/contact-form-7/blob/master/includes/js/scripts.js (line: 109)
Comments
Post a Comment