Good morning. I need to validate the CEP typed in an input. If the CEP is equal to 35000-000, you must clear the input and send CEP message Not Available. Is there any way to do this using the HTML pattern attribute? How to do?
void validaCEP(){
var cep = document.commentForm.cep
if (cep == '35300-000'){
alert('CEP Indisponível')
document.commentForm.cep.focus
alert(cep);
}
}
Thank you.