]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Plugin/inline.pm
Merge branch 'master' of ssh://git.kitenet.net/srv/git/ikiwiki.info
[git.ikiwiki.info.git] / IkiWiki / Plugin / inline.pm
index bb160ac4de949058cc62be656686058d717bb71b..b16636a705b80b39404476e0ebfe448561ad6c22 100644 (file)
@@ -161,16 +161,20 @@ sub preprocess_inline (@) { #{{{
        }
        else {
                if (exists $page_numfeeds{$params{destpage}}) {
        }
        else {
                if (exists $page_numfeeds{$params{destpage}}) {
-                       $feednum=$knownfeeds{$feedid}=++$page_numfeeds{$params{destpage}};
+                       if ($feeds) {
+                               $feednum=$knownfeeds{$feedid}=++$page_numfeeds{$params{destpage}};
+                       }
                }
                else {
                        $feednum=$knownfeeds{$feedid}="";
                }
                else {
                        $feednum=$knownfeeds{$feedid}="";
-                       $page_numfeeds{$params{destpage}}=1;
+                       if ($feeds) {
+                               $page_numfeeds{$params{destpage}}=1;
+                       }
                }
        }
 
                }
        }
 
-       my $rssurl=basename(rsspage($params{destpage}).$feednum);
-       my $atomurl=basename(atompage($params{destpage}).$feednum);
+       my $rssurl=basename(rsspage($params{destpage}).$feednum) if $feeds && $rss;
+       my $atomurl=basename(atompage($params{destpage}).$feednum) if $feeds && $atom;
        my $ret="";
 
        if ($config{cgiurl} && (exists $params{rootpage} ||
        my $ret="";
 
        if ($config{cgiurl} && (exists $params{rootpage} ||
@@ -221,7 +225,7 @@ sub preprocess_inline (@) { #{{{
                                }
                                $template->param(pageurl => urlto(bestlink($params{page}, $page), $params{destpage}));
                                $template->param(title => pagetitle(basename($page)));
                                }
                                $template->param(pageurl => urlto(bestlink($params{page}, $page), $params{destpage}));
                                $template->param(title => pagetitle(basename($page)));
-                               $template->param(ctime => displaytime($pagectime{$page}));
+                               $template->param(ctime => displaytime($pagectime{$page}, $params{timeformat}));
        
                                if ($actions) {
                                        my $file = $pagesources{$page};
        
                                if ($actions) {
                                        my $file = $pagesources{$page};