From 81d0bd72c0fbd6e06564d06f40f9463d931d9b80 Mon Sep 17 00:00:00 2001 From: Benjamin Southall Date: Sun, 21 Apr 2019 20:20:21 +1000 Subject: [PATCH] Add support for gopher url:// markup as hyperlinks --- inc/functions.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/functions.php b/inc/functions.php index d77149bd..85b56e58 100755 --- a/inc/functions.php +++ b/inc/functions.php @@ -1959,7 +1959,7 @@ function markup(&$body, $track_cites = false, $op = false) { $markup_urls = array(); $body = preg_replace_callback( - '/((?:https?:\/\/|ftp:\/\/|irc:\/\/)[^\s<>()"]+?(?:\([^\s<>()"]*?\)[^\s<>()"]*?)*)((?:\s|<|>|"|\.||\]|!|\?|,|,|")*(?:[\s<>()"]|$))/', + '/((?:https?:\/\/|ftp:\/\/|irc:\/\/|gopher:\/\/)[^\s<>()"]+?(?:\([^\s<>()"]*?\)[^\s<>()"]*?)*)((?:\s|<|>|"|\.||\]|!|\?|,|,|")*(?:[\s<>()"]|$))/', 'markup_url', $body, -1,