$params{linktext} = $linktext unless defined $params{linktext};
- if ($params{page} ne $params{destpage}) {
+ if ($params{page} ne $params{destpage} &&
+ (! exists $params{pages} ||
+ pagespec_match($params{destpage}, $params{pages},
+ location => $params{page}))) {
return "\n".
htmllink($params{page}, $params{destpage}, $params{page},
linktext => $params{linktext},
ikiwiki (3.20101113) UNRELEASED; urgency=low
* websetup: Fix encoding problem when restoring old setup file.
+ * more: Add pages parameter to limit where the more is displayed.
+ (thanks, dark)
-- Joey Hess <joeyh@debian.org> Tue, 16 Nov 2010 14:23:47 -0400
If the `linktext` parameter is omitted it defaults to just "more".
+An optional `pages` parameter can be used to specify a
+[[ikiwiki/PageSpec]], and then the "more" link will only be displayed
+when the page is inlined into a page matching that PageSpec, and otherwise
+the full content shown.
+
Note that you can accomplish something similar using a [[toggle]] instead.
[[!meta robots="noindex, follow"]]
I'm not entirely happy with the design, since I would rather put this information in the inline directive instead of in every story post. Unfortunately I found no way to pass parameters from the inline directive to the inlined page.
-- [[dark]]
+
+> Me neither, but nor do I see a better way, so [[applied|done]]. --[[Joey]]