On Thu, Mar 20, 2008 at 10:04:21 +0100, Benoit Timbert <[EMAIL PROTECTED]> wrote: > Selon Bruno Wolff III <[EMAIL PROTECTED]>: > > > On Tue, Mar 18, 2008 at 09:55:38 -0000, > > [EMAIL PROTECTED] wrote: > > > + //Are there any other non alpha-numeric characters allowed in email > > addresses? > > > + return ((c == '_') || (c == '-') || (c == '.')); > > > > Yes. Any non white space ascii character can be in the local part of an > > email > > address. > > > > Better have a look at the SMTP RFC, it's RFC 821.
Actually these days its 2821. That covers how email addresses are encoded for the envelope addresses. (RFC 2822 covers how email addresses are encoded for headers.) By looking at that you can tell what strings can be encoded (and hence are possible email addresses). You also have to decide which encoding you are going to store (there is the email address, its RFC 2821 encoding or its RFC 2822 encoding to choose from) unless you decide to only allow a subset of email addresses (which may be a good idea for this project's use). There are also oddities with the domain names in that it is possible to specify domain literals that are IP addresses. (Those are meant for testing and not general use though, so I don't think they need to be supported.) At the very least though, I recommend adding '+' to the list since that does get some use in practice. _______________________________________________ Wesnoth-dev mailing list [email protected] https://mail.gna.org/listinfo/wesnoth-dev
