|
On Mon, 2006-02-13 at 10:42 -0500, Fisher, Don wrote: > I'm creating a function to determine if an e-mail address is syntactically > correct and that its domain can handle e-mail. I found Scott Klement's > excellent code for this at the following link: > http://www.iseriesnetwork.com/resources/clubtech/index.cfm?fuseaction=ShowNe > wsletterIssue&ID=17632 > > I've noticed, however, that this function assumes a domain name is okay if > it exists, even though it may not be able to handle e-mail. An example is > test.com, where the e-mail addresses are actually testcentral.com. > Presumably, mail sent to the test.com address would be rejected. > > I modified the code slightly to always search for a mail exchanger and that > seems to work except for our own domain (roomstore.com). > > Would one of you kind folks set me straight as to how this stuff is supposed > to work? I'm obviously not understanding this very well. > This might help: http://www.dnsstuff.com/tools/mail.ch?domain=dfisher%40roomstore.com I think the steps are: Locate mail exchanger IP's via the DNS records If you can't locate the mx, the address is no good. Contact mail exchanger(s) on smtp port. If you can't connect, the address is suspect, but may still be good as the mail exchanger may be down. That's as far as you can go, practically speaking. You could try to send a mail to the address. Some mail servers will reject unknown users at the gateway, but other ones don't as a security measure, and you won't be able to tell which don't. The only way to know for sure it to actually send an e-mail to the address and have the user click a specially designed link. The special link embeds enough data in it so you can go back to your database and mark the e-mail address as valid. Since you've subscribed to this mailing list, you've already been through such a process from the user side. HTH Regards, Rich
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.