From cb78be1f17678911bf829e975621e85e3f24b612 Mon Sep 17 00:00:00 2001 From: Daniel Winzen Date: Thu, 8 Dec 2016 20:47:28 +0100 Subject: [PATCH] Fix posting, when using regex characters in a url --- chat.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chat.php b/chat.php index 54b6a73..d454497 100644 --- a/chat.php +++ b/chat.php @@ -3038,7 +3038,7 @@ function apply_linkfilter($message){ }elseif(preg_match_all('/(.*?(?=<\/a>))<\/a>/u', $message, $matches)){ foreach($matches[1] as $match){ if(!preg_match('~^http(s)?://~u', $match)){ - $message=preg_replace_callback('/(.*?(?=<\/a>))<\/a>/u', + $message=preg_replace_callback('/(.*?(?=<\/a>))<\/a>/u', function ($matched) use($redirect){ return "$matched[2]"; }