How can I address the input field to set the setCustomValidity? It does not work:
js fiddle
$('#numberinput').val("").setCustomValidity('The two email addresses must match.');
Using jQuery
you could do the following:
$('#numberinput').get(0).setCustomValidity('The two email addresses must match.');
And not:
$('#numberinput').val("").setCustomValidity('The two email addresses must match.');
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With