I need to validate an email address which will be transmitted to several possible state and federal agencies, each which may reject the entire form if the email address does not meet their validation requirements. (Some reject perfectly valid characters while others don't validate it at all and still others don't even support an email address field)
My choices are:
- Create a single address validator which is incredibily strict.
- Create a very loose validator for the main entry then revalidate with a custom validator for each agency as need dictates prior to transmitting each form.
- Something I haven't thought of?
I'm leaning toward the second, even though it will mean more work because it won't force the user to create an additional email account unless a particular agency refuses to accept their normal one.
I know this is really the agency's problem if they reject a perfectly legal email address but requests to fix these kind of things take a while to get answered and when something goes wrong customers don't blame the agency, they blame the software. (Even if its their own typographical error)