if (! defined $params{link} || lc($params{link}) eq 'yes') {
return '<a href="'.$fileurl.'">'.$imgtag.'</a>';
}
+ elsif (length bestlink($params{page}, $params{link})) {
+ return htmllink($params{page}, $params{destpage},
+ $params{link}, linktext => $imgtag);
+ }
else {
return $imgtag;
}
are not included in the map. Include special styling for such pages.
* map: Remove common prefixes and don't over-indent.
* Add class option to htmllink().
+ * img: Allow link=somepage to cause the image to link to a given page.
+ Slight overriding of link, as link=no is still used to disable the linking
+ entirely. Unless you have a page named "no"..
- -- Joey Hess <joeyh@debian.org> Sat, 22 Sep 2007 12:31:22 -0400
+ -- Joey Hess <joeyh@debian.org> Sat, 22 Sep 2007 12:36:37 -0400
ikiwiki (2.8) unstable; urgency=low
unchanged to the html img tag.
The `link` parameter is used to control whether the scaled down image links
-to the full size version. By default it does; set "link=no" to disable
-this.
+to the full size version. By default it does; set "link=somepage" to link
+to another page instead, or "link=no" to disable the link.
You can also set default values that will be applied to all later images on
the page, unless overridden. Useful when including many images on a page.
logo link to \[[hurd/logo]] / <http://www.bddebian.com/~wiki/hurd/logo/>
instead of linking to the PNG image file. --[[tschwinge]]
+> Done, use link=somepage --[[Joey]]