From 5cb814869daf6f20568e5af0849c458f7daabaa1 Mon Sep 17 00:00:00 2001 From: Graham Cole <chckens@sucs.org> Date: Tue, 21 Oct 2008 00:29:12 +0000 Subject: [PATCH] tweak hyperlink regex to (hopefully) drop properties other than href --- components/motd.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/motd.php b/components/motd.php index 33d938e..0eebddb 100644 --- a/components/motd.php +++ b/components/motd.php @@ -40,7 +40,7 @@ $body = str_replace("<li>", " * ", $body); $body = str_replace("</li>", "\n ", $body); $body = str_replace(" ", " ", $body); // remove hyperlinks, collect to display later -$body = preg_replace(":<a href=['\"](.+?)['\"]>(.*?)</a>:e", "'\\2['.linkcounter('\\1').']'", $body); +$body = preg_replace(":<a href=['\"](.+?)['\"].*?>(.*?)</a>:e", "'\\2['.linkcounter('\\1').']'", $body); $body = strip_tags($body); if (isset($uris)) { $body .= "----\n"; -- GitLab