Oops, invalid chars in bracketed external links should
authorWil Mahan <wmahan@users.mediawiki.org>
Mon, 11 Oct 2004 19:15:24 +0000 (19:15 +0000)
committerWil Mahan <wmahan@users.mediawiki.org>
Mon, 11 Oct 2004 19:15:24 +0000 (19:15 +0000)
be added to the link description, not the trail.

includes/Parser.php

index e516969..04ac280 100644 (file)
@@ -942,7 +942,7 @@ class Parser
                        # removeHTMLtags()) should not be included in
                        # URLs, per RFC 2396.
                        if (preg_match('/&(lt|gt);/', $url, $m2, PREG_OFFSET_CAPTURE)) {
-                               $trail = substr($url, $m2[0][1]) . $trail;
+                               $text = substr($url, $m2[0][1]) . ' ' . $text;
                                $url = substr($url, 0, $m2[0][1]);
                        }