diff options
author | Joas Schilling <nickvergessen@gmx.de> | 2014-11-22 12:13:39 +0100 |
---|---|---|
committer | Joas Schilling <nickvergessen@gmx.de> | 2014-11-22 12:13:39 +0100 |
commit | 7700f3121344c655739badd24cff27f4c66f0566 (patch) | |
tree | 61c9a938ba1e4986b0462b1d9bf8f005399e9580 /phpBB/includes/message_parser.php | |
parent | a83b952f63b244e55471a78453aa54febe822565 (diff) | |
parent | 483af1d036aadf8bd7d3b4c76a1fe97409238547 (diff) | |
download | forums-7700f3121344c655739badd24cff27f4c66f0566.tar forums-7700f3121344c655739badd24cff27f4c66f0566.tar.gz forums-7700f3121344c655739badd24cff27f4c66f0566.tar.bz2 forums-7700f3121344c655739badd24cff27f4c66f0566.tar.xz forums-7700f3121344c655739badd24cff27f4c66f0566.zip |
Merge pull request #3116 from rxu/ticket/13297
[ticket/13297] Add unicode modifier to url/email regular expression patterns
Diffstat (limited to 'phpBB/includes/message_parser.php')
-rw-r--r-- | phpBB/includes/message_parser.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/phpBB/includes/message_parser.php b/phpBB/includes/message_parser.php index bc996cf275..12ef94c07a 100644 --- a/phpBB/includes/message_parser.php +++ b/phpBB/includes/message_parser.php @@ -313,7 +313,7 @@ class bbcode_firstpass extends bbcode $in = str_replace(' ', '%20', $in); // Checking urls - if (!preg_match('#^' . get_preg_expression('url') . '$#i', $in) && !preg_match('#^' . get_preg_expression('www_url') . '$#i', $in)) + if (!preg_match('#^' . get_preg_expression('url') . '$#i', $in) && !preg_match('#^' . get_preg_expression('www_url') . '$#iu', $in)) { return '[img]' . $in . '[/img]'; } @@ -381,8 +381,8 @@ class bbcode_firstpass extends bbcode $in = str_replace(' ', '%20', $in); // Make sure $in is a URL. - if (!preg_match('#^' . get_preg_expression('url') . '$#i', $in) && - !preg_match('#^' . get_preg_expression('www_url') . '$#i', $in)) + if (!preg_match('#^' . get_preg_expression('url') . '$#iu', $in) && + !preg_match('#^' . get_preg_expression('www_url') . '$#iu', $in)) { return '[flash=' . $width . ',' . $height . ']' . $in . '[/flash]'; } @@ -973,9 +973,9 @@ class bbcode_firstpass extends bbcode $url = str_replace(' ', '%20', $url); // Checking urls - if (preg_match('#^' . get_preg_expression('url') . '$#i', $url) || - preg_match('#^' . get_preg_expression('www_url') . '$#i', $url) || - preg_match('#^' . preg_quote(generate_board_url(), '#') . get_preg_expression('relative_url') . '$#i', $url)) + if (preg_match('#^' . get_preg_expression('url') . '$#iu', $url) || + preg_match('#^' . get_preg_expression('www_url') . '$#iu', $url) || + preg_match('#^' . preg_quote(generate_board_url(), '#') . get_preg_expression('relative_url') . '$#iu', $url)) { $valid = true; } |