Template:PDFLink: Difference between revisions
template>Tomoneill (add cat) |
m (Text replacement - "Powerpedia" to "Saintapedia") |
||
(One intermediate revision by one other user not shown) | |||
Line 6: | Line 6: | ||
"params": { | "params": { | ||
"1": { | "1": { | ||
"label": " | "label": "Saintapedia filename.pdf", | ||
"required": true, | "required": true, | ||
"description": "Type the name of the file you want to link to. It is not necessary to include File: at the start of the name.", | "description": "Type the name of the file you want to link to. It is not necessary to include File: at the start of the name.", | ||
Line 18: | Line 18: | ||
} | } | ||
}, | }, | ||
"description": "Creates a direct link to Acrobat PDF files stored on | "description": "Creates a direct link to Acrobat PDF files stored on Saintapedia, followed by a PDF icon and a link to the Saintapedia page for the file.", | ||
"format": "inline" | "format": "inline" | ||
} | } |
Latest revision as of 20:43, 16 September 2024
[[Media:{{{1}}}|{{{1}}}]] [[:Image:{{{1}}}|Link]]
These Media templates assist in linking to PDF documents that have been uploaded to Saintapedia. Clicking on the linked text preceding the file icon takes you to the document, while clicking on the "Link" text following the icon takes you to the Saintapedia page for the document.
See Help:Files for a complete description of how to upload files correctly and see Help:Templates for information on templates. Help:Media templates provides information about these templates as well.
It is not necessary to include File:
at the start of the file name in these templates, but the templates will still work if it is included. The templates will not work, however, if Media:
or Image:
are used instead.
PDF file links
For PDF files, you can also link to them as an image instead using the {{PDFLink}}
template. This approach will show an image of the first page of the PDF file. The same display options are available as for other image files, plus an additional option (|page=
) is available to specify which page of the PDF to display. See below for an example and see help:images for more details.
Examples
What to Type | Example | Explanation |
---|---|---|
{{PDFLink | Saintapedia test.pdf | Saintapedia test }}
|
Saintapedia test Link | Link to a Adobe PDF (.pdf) file and show icon |
{{PDFLink | Saintapedia test.pdf }}
|
Saintapedia test.pdf Link | |
[[File:Saintapedia test.pdf | Saintapedia test | 300px]]
|
A direct link to a PDF file, rather than using {{PDFLink}} will show the first page of the PDF file as an image. See Extension:PdfHandler#Usage for more information.
|
Creates a direct link to Acrobat PDF files stored on Saintapedia, followed by a PDF icon and a link to the Saintapedia page for the file.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Saintapedia filename.pdf | 1 | Type the name of the file you want to link to. It is not necessary to include File: at the start of the name. | File | required |
Link label | 2 | Add alternate text if you want something other than the filename to be shown (for instance, if you don't want to show .pdf at the end). | String | suggested |