Michael Pavling wrote:
> On 28 September 2010 17:29, Greg Donald <[email protected]> wrote:
>> On Tue, Sep 28, 2010 at 10:49 AM, Marnen Laibow-Koser
>> <[email protected]> wrote:
>>> Do not use regexes to validate e-mail addresses.
>>
>> Pffft.
> 
> Nah, I'm with Marnen on this. Trying to regex validate an email with
> 100% surety is a sure-fire way of annoying someone. 

I have seen regexes that purport to actually be correct for e-mail 
validation.  They are on the order of a page in length when printed in 
reasonably-sized type.

> Same with
> postcodes,

Really?  Shouldn't you at least be able to come up with 
*country-specific* regexes for those?

 > and even more so with names (can you believe that some
> people think they can regex what *name* a person may have - I've seen
> it; it's rubbish! :-)

As the proud bearer of a hyphenated last name, I am intimately familiar 
with this brand of rubbish.

> 
> You can probably regex close to all potential email addresses, but as
> Marnen says, the best way to validate an email address is to send an
> email to it.

Best,
-- 
Marnen Laibow-Koser
http://www.marnen.org
[email protected]
-- 
Posted via http://www.ruby-forum.com/.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to