Rollback for issue #12274 given that it does not consider email domain names with...
authorGábor Hojtsy
Fri, 24 Feb 2012 08:22:58 +0000 (09:22 +0100)
committerGábor Hojtsy
Fri, 24 Feb 2012 08:22:58 +0000 (09:22 +0100)
includes/common.inc

index e6fdca7..58fe6ae 100644 (file)
@@ -996,7 +996,7 @@ function t($string, $args = array(), $langcode = NULL) {
  */
 function valid_email_address($mail) {
   $user = '[a-zA-Z0-9_\-\.\+\^!#\$%&*+\/\=\?\`\|\{\}~\']+';
-  $domain = '(?:(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]*[a-zA-Z0-9])(\.[a-zA-Z0-9]+)*)+';
+  $domain = '(?:(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]*[a-zA-Z0-9])\.?)+';
   $ipv4 = '[0-9]{1,3}(\.[0-9]{1,3}){3}';
   $ipv6 = '[0-9a-fA-F]{1,4}(\:[0-9a-fA-F]{1,4}){7}';