showing results for - "js find 3ainvalid inside div"
Alejandro
10 May 2019
1var contactForm = document.getElementById('contact-form');
2if (contactForm.checkValidity() == false) {
3    var list = contactForm.querySelectorAll(':invalid');
4    for (var item of list) {
5        item.setAttribute("style", "background-color: red;")
6    }
7}
8
similar questions
queries leading to this page
js find 3ainvalid inside div