summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorAndrey Andreev <narf@devilix.net>2017-09-29 11:00:24 +0200
committerGitHub <noreply@github.com>2017-09-29 11:00:24 +0200
commitfccbf8802be41595c4a7c8b8b06dbc85333447ba (patch)
treeb72d9ff93fd5e5556fa888c06c64459fe0414e92 /system
parent1db998348e8850db79c4afa2d057fa31fb6bc12c (diff)
parent3e59801223f1393507d81e9f394c4f5ae33e1c04 (diff)
Merge pull request #5278 from Uekawa/auto_link
Fix auto_link trailing slash
Diffstat (limited to 'system')
-rwxr-xr-x[-rw-r--r--]system/helpers/url_helper.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/system/helpers/url_helper.php b/system/helpers/url_helper.php
index 99e82ef9f..421b3bad5 100644..100755
--- a/system/helpers/url_helper.php
+++ b/system/helpers/url_helper.php
@@ -393,7 +393,7 @@ if ( ! function_exists('auto_link'))
function auto_link($str, $type = 'both', $popup = FALSE)
{
// Find and replace any URLs.
- if ($type !== 'email' && preg_match_all('#(\w*://|www\.)[^\s()<>;]+\w#i', $str, $matches, PREG_OFFSET_CAPTURE | PREG_SET_ORDER))
+ if ($type !== 'email' && preg_match_all('#(\w*://|www\.)[^\s()<>;]+\w/?#i', $str, $matches, PREG_OFFSET_CAPTURE | PREG_SET_ORDER))
{
// Set our target HTML if using popup links.
$target = ($popup) ? ' target="_blank"' : '';