]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/CGI.pm
* Corrected a bum regexp in openid munging.
[git.ikiwiki.info.git] / IkiWiki / CGI.pm
index 83ed959c02a9d1d7d90fdc1ec8195f76f1608703..5d21d0674eca2b273aaeef28e77e5c418b62531a 100644 (file)
@@ -666,9 +666,9 @@ sub userlink ($) { #{{{
                if ($display !~ /\[/) {
                        $display=~s/^(.*?)\.([^.]+\.[a-z]+)$/$1 [$2]/;
                }
-               # Convert "somehost.com/user" to "user [somehost.com]".
+               # Convert "http://somehost.com/user" to "user [somehost.com]".
                if ($display !~ /\[/) {
-                       $display=~s/^(.+)\/[^\/](.+)$/$2 [$1]/;
+                       $display=~s/^https?:\/\/(.+)\/([^\/]+)$/$2 [$1]/;
                }
                $display=~s!^https?://!!; # make sure this is removed
                return "<a href=\"$user\">".escapeHTML($display)."</a>";