# that if they are removed or otherwise changed, the inline will be
# sure to be updated.
add_depends($params{page}, join(" or ", @list));
- # Force a scan of this page so any metadata that appears after this
- # inline directive is available when inlining. The page normally
- # wouldn't be scanned if it's only being rebuilt because of a
- # depedency.
- IkiWiki::scan($pagesources{$params{page}});
my $feednum="";
will_render($params{destpage}, $rssp);
if (! $params{preview}) {
writefile($rssp, $config{destdir},
- genfeed("rss", $rssurl, $desc, $params{destpage}, @list));
+ genfeed("rss",
+ $config{url}."/".rsspage($params{destpage}).$feednum, $desc, $params{destpage}, @list));
$toping{$params{destpage}}=1 unless $config{rebuild};
$feedlinks{$params{destpage}}=qq{<link rel="alternate" type="application/rss+xml" title="RSS" href="$rssurl" />};
}
will_render($params{destpage}, $atomp);
if (! $params{preview}) {
writefile($atomp, $config{destdir},
- genfeed("atom", $atomurl, $desc, $params{destpage}, @list));
+ genfeed("atom", $config{url}."/".atompage($params{destpage}).$feednum, $desc, $params{destpage}, @list));
$toping{$params{destpage}}=1 unless $config{rebuild};
$feedlinks{$params{destpage}}=qq{<link rel="alternate" type="application/atom+xml" title="Atom" href="$atomurl" />};
}
$url=~s/[^\/]+$//;
$content=~s/(<a(?:\s+(?:class|id)\s*="?\w+"?)?)\s+href=\s*"(#[^"]+)"/$1 href="$baseurl$2"/mig;
- $content=~s/(<a(?:\s+(?:class|id)\s*="?\w+"?)?)\s+href=\s*"(?!\w+:\/\/)([^"]+)"/$1 href="$url$2"/mig;
- $content=~s/(<img(?:\s+(?:class|id|width|height)\s*="?\w+"?)*)\s+src=\s*"(?!\w+:\/\/)([^"]+)"/$1 src="$url$2"/mig;
+ $content=~s/(<a(?:\s+(?:class|id)\s*="?\w+"?)?)\s+href=\s*"(?!\w+:)([^"]+)"/$1 href="$url$2"/mig;
+ $content=~s/(<img(?:\s+(?:class|id|width|height)\s*="?\w+"?)*)\s+src=\s*"(?!\w+:)([^"]+)"/$1 src="$url$2"/mig;
return $content;
} #}}}