With this recipe you can easily create a thumbnail link to a page that displays a full-size image, which in turn links back to the page containing the thumbnail link. Use several thumbnail links on a page to easily create an image gallery.
By default the thumbnail image will be 80px high. You can specify another height or a width, or both if you want to change the aspect ratio of the thumbnail.
## Enable (:thumb <image_filename>:) markup that displays an image. include_once("$FarmD/cookbook/thumblink.php");
Basic usage is just to do
The default thumbnail height is 75 pixels. A proportional width will be provided by the browser. Optionally you may specify a different width, a height, or both as in
(:thumb <image_filename> width=120:)
(:thumb <image_filename> height=100:)
(:thumb <image_filename> width=120 height=90:)
The script's code needs to be scrutinized by Pm and/or someone else who knows the PmWiki internals well (because I don't). Use at your own risk until then.
For this release, the image must be capable of being displayed with "
Attach:<image_filename>" without specifying any group or page. (Attachments can be by site, group, or page. The default is by group, meaning the image just needs to be uploaded in the same group.)
This recipe cannot be used together with ThumbList as they both have the same command
- Somehow use an #anchor to reduce scrolling.
If the recipe has multiple releases, then release notes can be placed here. Note that it's often easier for people to work with "release dates" instead of "version numbers".
- ThumbList - A thumbnail picture gallery for PmWiki
See discussion at ThumbnailLinkToImage-Talk