summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--IkiWiki.pm7
1 files changed, 6 insertions, 1 deletions
diff --git a/IkiWiki.pm b/IkiWiki.pm
index 4368870b8..6e03121c0 100644
--- a/IkiWiki.pm
+++ b/IkiWiki.pm
@@ -539,7 +539,12 @@ sub beautify_url ($) { #{{{
if ($config{usedirs}) {
$url =~ s!/index.$config{htmlext}$!/!;
}
- $url =~ s!^$!./!; # Browsers don't like empty links...
+
+ # Ensure url is not an empty link, and
+ # if it's relative, make that explicit to avoid colon confusion.
+ if ($url !~ /\//) {
+ $url="./$url";
+ }
return $url;
} #}}}