]> sipb.mit.edu Git - ikiwiki.git/commitdiff
cgiurl(): return a locally-valid path by default
authorSimon McVittie <smcv@debian.org>
Mon, 22 Nov 2010 23:20:32 +0000 (23:20 +0000)
committerSimon McVittie <smcv@debian.org>
Mon, 22 Nov 2010 23:47:04 +0000 (23:47 +0000)
To get an absolute version you can use cgiurl(cgiurl => $config{cgiurl}).
The only place in IkiWiki that seems to actually need an absolute URL
is the openid plugin, and that already uses the named parameter.

IkiWiki.pm

index 989f3bee7ca47b427f8ba68806db3c80a0117589..41e9e3f82d3cc89f44b953c8b3a47def74758fb4 100644 (file)
@@ -1039,7 +1039,8 @@ sub linkpage ($) {
 sub cgiurl (@) {
        my %params=@_;
 
-       my $cgiurl=$config{cgiurl};
+       my $cgiurl=$local_cgiurl;
+
        if (exists $params{cgiurl}) {
                $cgiurl=$params{cgiurl};
                delete $params{cgiurl};