[pmwiki-users] Image with link to attached file

Petko Yotov 5ko at 5ko.fr
Sun Sep 8 00:36:42 PDT 2024


On 07/09/2024 23:37, Michael Eager wrote:
> I'd like to have an uploaded file represented by an image.
> 
> I have a PowerPoint file which I'd like to show on a wiki page with a
> jpg of the title slide, perhaps with the file name as a caption.
> 
> I assume that I could have an image with a link to the file in the
> upload directory.  Is there more direct way to do this?

Indeed, you would create a thumbnail of the front page and attach both 
files. Something like this:

   [[Attach:file.pptx|Attach:file.pptx.jpg]] | Caption

It may be possible to write a PmWiki recipe/extension to extract an 
existing thumbnail from a PPTX file, and display it. It is not yet 
written, but would require the PPTX file to be saved with a thumbnail 
from the menus or the ribbon "File" -> "Info" or "Properties/Summary" -> 
"Save preview picture".

Otherwise you can just show an appropriate icon, this may help you get 
started:

   https://www.pmwiki.org/wiki/Cookbook/LinkIcons

Petko




More information about the pmwiki-users mailing list