Commit ea60fb75 authored by Nathan Haug's avatar Nathan Haug
Browse files

#278800 by Moonshine. Error in e-mail valididity regex.

parent 4a45823f
......@@ -678,10 +678,10 @@ function link_validate_url($text) {
$anchor = "(#[a-z0-9_\-\.~+%=&,$'():;*@\[\]]*)";
// The rest of the path for a standard URL.
$end = $directories . '?' . $query . '?' . $anchor . '?' . '$/i';
$end = $directories . '?' . $query . '?' . $anchor . '?' . '$/i';
$user = '[a-zA-Z0-9_\-\.\+\^!#\$%&*+\/\=\?\`\|\{\}~\'\[\]]+';
$email_pattern = '/^mailto:' . $user . '@' . '(' . $domain . '|' . $ipv4 .'|'. $ipv6 . '|localhost)' . $query . '$/';
$email_pattern = '/^mailto:' . $user . '@' . '(' . $domain . '|' . $ipv4 .'|'. $ipv6 . '|localhost)' . $query . '?$/';
if (strpos($text, '<front>') === 0) {
return LINK_FRONT;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment