Skip to content

Commit bf5bfe4

Browse files
[5.3] Allow email addresses with an underscore (joomla#45102)
1 parent 59b7f62 commit bf5bfe4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugins/content/emailcloak/src/Extension/EmailCloak.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ private function cloak($text)
160160
$mode = $mode === 1;
161161

162162
// Example: [email protected]
163-
$searchEmail = "([\p{L}\p{N}\.\'\-\+]+\@(?:[\.\-\p{L}\p{N}]+\.)+(?:[\-\p{L}\p{N}]{2,24}))";
163+
$searchEmail = "([\p{L}\p{N}\.\'\-\+\_]+\@(?:[\.\-\p{L}\p{N}]+\.)+(?:[\-\p{L}\p{N}]{2,24}))";
164164

165165
// Example: [email protected]?subject=anyText
166166
$searchEmailLink = $searchEmail . '([?&][\x20-\x7f][^"<>]+)';

0 commit comments

Comments
 (0)