What I want to do is to validate an email address with exact gmail or yahoo word and I have tried the following but failed:
/^[a-z0-9._%+-]+@[^gmail$.-]+\.[a-z]{2,}$/
suppose if anyone mistakenly tried to sign up using [email protected] or [email protected] or [email protected] or something like that. How can I validate that??