<script> //function to check for a specific email address function donotreply() { if (document.forms["reply"]["send_to"].value == 'do-not-reply@example.com') { alert('You would try to send to the one address yer not allowed to....try again!'); return false; } return true; } </script>
And the form entries…
<form name="reply" onsubmit="return donotreply()"> <input type="text" name="send_to">
Hi Scott,
Just to like to thank you for the information.
I run an online bulletin board for my co-workers and had been seeking how to check a particular someone’s entry as she kept ignoring social etiquette.
This script should work nicely. 😉
Thanks again and keep up great work!
Awesome, glad it worked for you. Thanks for the feedback! 🙂
Hello again,
I wonder if there is also a way to check for bad words within email address?
Thanks in advance for your expertise.
Certainly,
http://sudobash.net/?p=181
I’m not sure exactly how to implement that in conjunction with this without testing and I don’t have the time to test right now but that should get you started. 🙂
Thanks kindly for your speedy response! I will see if I can manage to work on it. 🙂