]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Plugin/template.pm
Renamed postscan hook to indexhtml, to reflect its changed position.
[git.ikiwiki.info.git] / IkiWiki / Plugin / template.pm
index d2b2fef55fbec15fef890f52c7cb9c2f0d56d3e6..b8c2f05b29ab4492453a91b16dff76f8d1521228 100644 (file)
@@ -53,15 +53,17 @@ sub preprocess (@) {
 
        foreach my $param (keys %params) {
                my $value=IkiWiki::preprocess($params{page}, $params{destpage},
-                         IkiWiki::filter($params{page}, $params{destpagea},
+                         IkiWiki::filter($params{page}, $params{destpage},
                          $params{$param}), $scan);
                if ($template->query(name => $param)) {
-                       $template->param($param =>
-                               IkiWiki::htmlize($params{page}, $params{destpage},
+                       my $htmlvalue=IkiWiki::htmlize($params{page}, $params{destpage},
                                        pagetype($pagesources{$params{page}}),
-                                       $value));
+                                       $value);
+                       chomp $htmlvalue;
+                       $template->param($param => $htmlvalue);
                }
                if ($template->query(name => "raw_$param")) {
+                       chomp $value;
                        $template->param("raw_$param" => $value);
                }
        }