]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Plugin/inline.pm
Merge branch 'master' of ssh://git.ikiwiki.info/srv/git/ikiwiki.info
[git.ikiwiki.info.git] / IkiWiki / Plugin / inline.pm
index 933e30646d51bc22fb377df5d288245008c94b38..20c5f3bddc08473bd06f27dfa5f5c3e35e1b22c0 100644 (file)
@@ -476,6 +476,13 @@ sub get_inline_content ($$) {
                       filter($page, $destpage,
                       readfile(srcfile($file))))));
                $nested--;
+               if (isinternal($page)) {
+                       # make inlined text of internal pages searchable
+                       run_hooks(indexhtml => sub {
+                               shift->(page => $page, destpage => $page,
+                                       content => $ret);
+                       });
+               }
        }
        
        if ($cached_destpage ne $destpage) {
@@ -563,9 +570,9 @@ sub genfeed ($$$$$@) {
                        }
                }
 
+               my $file=$pagesources{$p};
+               my $type=pagetype($file);
                if ($itemtemplate->query(name => "enclosure")) {
-                       my $file=$pagesources{$p};
-                       my $type=pagetype($file);
                        if (defined $type) {
                                $itemtemplate->param(content => $pcontent);
                        }
@@ -584,6 +591,7 @@ sub genfeed ($$$$$@) {
                        }
                }
                else {
+                       next unless defined $type;
                        $itemtemplate->param(content => $pcontent);
                }