Jump to content

Timothy.Prinsloo

Members
  • Content Count

    3
  • Joined

  • Last visited

Community Reputation

0 Neutral
  1. Timothy.Prinsloo

    Regex help please..

    @Attila Kovacs & @Lars Fosdal Thanks for all the help. I went with this as my solution EMAIL_REGEX = '^((((?>[a-zA-Z\d!#$%&’“”''*+\-\/=?^_`{|}~]+\x20*|"((?=[\x01-\x7f])' +'[^"\\]|\\[\x01-\x7f])*"\x20*)*(?<angle><))?((?!\.)' +'(?>\.?[a-zA-Z\d!#$%&’“”''*+\-\/=?^_`{|}~]+)+|"((?=[\x01-\x7f])' +'[^"\\]|\\[\x01-\x7f])*")@(((?!-)[a-zA-Z\d\-]+(?<!-)\.)+[a-zA-Z]{2,}|(((?(?<!)\.)' +'(25[0-5]|2[0-4]\d|[01]?\d?\d)){4}|[a-zA-Z\d\-]*[a-zA-Z\d]:((?=[\x01-\x7f])' +'[^\\\[\]]|\\[\x01-\x7f])+)\])(?(angle)>))(;\S)*)+$|' +'(\p{L}+([-+.]\p{L}+)*@\p{L}+([-.]\p{L}+)*\.\p{L}+([-.]\p{L}+)*$)';
  2. Timothy.Prinsloo

    Regex help please..

    @Attila Kovacs just out of interest does work in Delphi... I know it works for C# but isn't the regex syntax different between the two languages \p{L}+([-+.']\p{L}+)*@\p{L}+([-.]\p{L}+)*\.\p{L}+([-.]\p{L}+)*$ 
  3. Timothy.Prinsloo

    Regex help please..

    @Fr0sT.Brutal speaking of International Domain Names any ideas I still have to validate the Latin alphabet with diacritics Pelé@example.com Greek alphabet δοκιμή@παράδειγμα.δοκιμή Traditional Chinese characters 我買@屋企.香港 Japanese characters 二ノ宮@黒川.日本 Cyrillic characters медведь@с-балалайкой.рф Devanagari characters संपर्क@डाटामेल.भारत using the same RegEx as OP
×