Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 7 of 7
  1. #1
    Junior Member
    Join Date
    Oct 2003
    Location
    Barcelona
    Posts
    20
    Member #
    3732
    I have an e-mail validation function according to the official rule achieved in another forum and it seems reliable, anyway I need to find out the organization and the document where this rule is defined, I suppose that in the W3C (World Wide Web Consortium) http://www.w3.org/ , but I can not achieve to find out the document in this site.

    Somebody can help me finding the original rule and the updates?

    Thanks,
    Cesar

  2.  

  3. #2
    WDF Staff smoseley's Avatar
    Join Date
    Mar 2003
    Location
    Boston, MA
    Posts
    9,729
    Member #
    819
    Liked
    205 times
    I don't think there's an "official rule" per se, but rather allowed domain names (check ICANN maybe?) and allowable characters and length of an email address (not sure where that would be defined).

    I think you can get a rater simple regex that will handle all emails (with a 1% slippage or so).

  4. #3
    Senior Member nsr81's Avatar
    Join Date
    Oct 2002
    Posts
    1,132
    Member #
    250
    Liked
    15 times
    what steve said. I usually keep the following in mind when trying to validate email addresses.

    - mimimum length should be 6, there is at least 1 character, followed by @, then at least one character, followed by a dot (.), and then at least two characters. (Last two characters are minimum length of a valid domain extension). This would be something like a@b.ca

    - Allowable characters, a-z, A-Z, 0-9, ., -, and _
    There and Back Again :Ogre:

  5. #4
    WDF Staff smoseley's Avatar
    Join Date
    Mar 2003
    Location
    Boston, MA
    Posts
    9,729
    Member #
    819
    Liked
    205 times
    so, very simply,
    Code:
    [a-zA-Z0-9\.\-\_]+\@[a-zA-Z0-9\.\-\_]+\.[a-zA-Z]+
    Something like that :-D

  6. #5
    WDF Staff smoseley's Avatar
    Join Date
    Mar 2003
    Location
    Boston, MA
    Posts
    9,729
    Member #
    819
    Liked
    205 times
    I always mix up plus (+) and pound (#) in regex... one is "one or more pattern matches minimal" and one is "one or more pattern matches maximal", but I can't recall which is which.

  7. #6
    Senior Member nsr81's Avatar
    Join Date
    Oct 2002
    Posts
    1,132
    Member #
    250
    Liked
    15 times
    LOL yup, that + should do it
    There and Back Again :Ogre:

  8. #7
    Junior Member
    Join Date
    Oct 2003
    Location
    Barcelona
    Posts
    20
    Member #
    3732
    Perfect, friends !! Is the piece of advice that I really needed. I am fed up with the e-mail validation and all the untruth and complex theories :tired:.
    The most part of websites I have seen accepts all the e-mail addresses with this minimum rules 'minimum1char@minimum1char.between2and4char', I think that it' s enough.

    Thank you very much :ichathappy:,
    Cesar


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 11:09 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2020 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com