Search…

X3 Photo Gallery Support Forums

Search…
 
cmodesign
Topic Author
Posts: 4
Joined: 15 Nov 2023, 14:14

Create hyperlinks for images that link to PDF

16 Nov 2023, 12:59

I am looking for a way to post PDFs that are viewable and downloadable. I don't think there is a way to have PDFs viewable in Galleries. But if I could create a JPG thumbnail and add a hyperlink that opens the PDF, or a download button for the PDF that would be ideal.

I see there is a way to add hyperlinks to images, but  I cannot figure out how or where to add these links. Is this a licensed feature?
https://demo.photo.gallery/examples/features/image-links/
 
User avatar
JMM
Experienced
Posts: 154
Joined: 02 Aug 2021, 11:18

Re: Create hyperlinks for images that link to PDF

16 Nov 2023, 17:36

Refer to the sample screenshot below:
  1. Copy your PDF file into a gallery in X3;
  2. Hide that PDF file in X3;
  3. Copy the thumbnail that you wish to use into that same X3 gallery;
  4. For the thumbnail (not the PDF file), in the Link field, enter in the name of the PDF file (with the PDF extension).
Example: if your PDF is called thisismypdf.pdf , enter in the Link field:
{path}thisismypdf.pdf
Note the text {path} in front of the filename... that tells X3 to look for the PDF file in the same folder (gallery) that the thumbnail is in.  You don't actually put the folder name in there... you enter it exactly as shown above (except with the actual filename of the PDF file).

You can experiment with the auto | _self | _blank | popup window | X3 popup choices, to see which works best for you.

Image

Don't forget to hide the actual PDF file, although in creating the above screenshot, my X3 didn't display the PDF anyway, but hiding it is a good reminder to you that the actual PDF will only get displayed when your users click on the thumbnail itself.

Regards,
John
Location: Burlington (Toronto-ish), Ontario, Canada
Self-hosted using Abyss Web Server:   AuroraWings.me   |   GalleryWings.com   |   PanAurora-Studio.com   |
Externally-hosted using LiteSpeed/Apache Web Server:   GenealogyWings.com/galleries   |
 
User avatar
JMM
Experienced
Posts: 154
Joined: 02 Aug 2021, 11:18

Re: Create hyperlinks for images that link to PDF

16 Nov 2023, 17:38

In my example in the screenshot, I created a PNG thumbnail, but as you mentioned, you can make it a JPG instead, which would probably be a smaller filesize than a PNG.
Location: Burlington (Toronto-ish), Ontario, Canada
Self-hosted using Abyss Web Server:   AuroraWings.me   |   GalleryWings.com   |   PanAurora-Studio.com   |
Externally-hosted using LiteSpeed/Apache Web Server:   GenealogyWings.com/galleries   |
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13998
Joined: 30 Sep 2006, 03:37

Re: Create hyperlinks for images that link to PDF

16 Nov 2023, 21:49

cmodesign wrote: I am looking for a way to post PDFs that are viewable and downloadable. I don't think there is a way to have PDFs viewable in Galleries. But if I could create a JPG thumbnail and add a hyperlink that opens the PDF, or a download button for the PDF that would be ideal.

I see there is a way to add hyperlinks to images, but  I cannot figure out how or where to add these links. Is this a licensed feature?
https://demo.photo.gallery/examples/features/image-links/
In general, X3 does not support PDF or any non-image formats. You can of course link manually to PDF files that you have uploaded, and if you want thumbnails, there are some great tips above from @JMM.

On a side note, the Files Gallery application (included with your X3), does support PDF files:
https://demo.files.gallery/?files#filter=pdf

It does not create PDF thumbnails. This is because this is not within the default capabilities of PDF, and personally, I have never seen PDF preview images that make much sense or provide any meaningful output, as they all just look like miniature unreadable text.