Commit d539eb27 authored by Nigel McNie's avatar Nigel McNie

Add the 'm' modifier to the autolink_text regex.

Catches URLs that are on lines by themselves. Spotted by Stephen Coles.
Signed-off-by: default avatarNigel McNie <nigel@catalyst.net.nz>
parent 4f741fef
......@@ -2449,7 +2449,7 @@ function html2text($html) {
*/
function autolink_text($text) {
$text = preg_replace(
'#(^|.)(https?://\S+)#e',
'#(^|.)(https?://\S+)#me',
"_autolink_text_helper('$2', '$1')",
$text
);
......
Markdown is supported
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