Template:Download link/doc: Difference between revisions
Created page with " {{Download link|media=Gitlab-logo-500-rgb.png}} {{Download link|media=Gitlab-logo-500-rgb.png|hello}} {{Download link|media=Gitlab-logo-500-rgb.png|hello|png}} {{Download..." |
mNo edit summary |
||
| (3 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
To be used with links that point directly to a downloadable file. This template will place an icon in front to differentiate download links from regular links, so users don't accidentally download anything. | |||
Can be used with both internal and external files. | |||
{{Download link|media= | ==Usage== | ||
===Wiki files=== | |||
<pre>{{Download link|media=<file>|<description>|<extension>}}</pre> | |||
<code>file</code> The file name of the uploaded file (what comes after Media: or File:).<br/> | |||
<code>description</code> description to display instead of the filename.<br/> | |||
<code>extension</code> file extension; will be displayed in brackets behind the link. | |||
{{Download link|media= | ====Examples==== | ||
{{Download link|media=Placeholder.png}} | |||
<pre>{{Download link|media=Placeholder.png}}</pre> | |||
{{Download link|media=Placeholder.png|Placeholder image}} | |||
<pre>{{Download link|media=Placeholder.png|Placeholder image}}</pre> | |||
{{Download link| | {{Download link|media=Placeholder.png|Placeholder image|png}} | ||
<pre>{{Download link|media=Placeholder.png|Placeholder image|png}}</pre> | |||
====File: links==== | |||
For linking to the File: page of a file that's uploaded to this wiki, you can use a regular internal link. This template is meant for links that directly open or download a file. | |||
Linking to a file's File: page can be useful, for instance if you want to show the file's older versions, or to make sure the user sees the licensing conditions. | |||
{{Download link|https://tsgdoc.socsci.ru.nl/images/ | [[:File:Placeholder.png]] | ||
<pre>[[:File:Placeholder.png]]</pre> | |||
[[:File:Placeholder.png|Placeholder Image]] | |||
<pre>[[:File:Placeholder.png|Placeholder Image]]</pre> | |||
===External files=== | |||
<pre>{{Download link|<url>|<description>|<extension>}}</pre> | |||
<code>url</code> The full URL.<br/> | |||
<code>description</code> description to display instead of the filename.<br/> | |||
<code>extension</code> file extension; will be displayed in brackets behind the link. | |||
====Examples==== | |||
{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.png}} | |||
<pre>{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.png}}</pre> | |||
{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.png|Placeholder image}} | |||
<pre>{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.pngg|Placeholder image}}</pre> | |||
{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.png|Placeholder image|png}} | |||
<pre>{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.png|Placeholder image|png}}</pre> | |||
Latest revision as of 08:46, 11 August 2026
To be used with links that point directly to a downloadable file. This template will place an icon in front to differentiate download links from regular links, so users don't accidentally download anything.
Can be used with both internal and external files.
Usage
Wiki files
{{Download link|media=<file>|<description>|<extension>}}
file The file name of the uploaded file (what comes after Media: or File:).
description description to display instead of the filename.
extension file extension; will be displayed in brackets behind the link.
Examples
{{Download link|media=Placeholder.png}}
{{Download link|media=Placeholder.png|Placeholder image}}
⬇️Placeholder image (png)
{{Download link|media=Placeholder.png|Placeholder image|png}}
File: links
For linking to the File: page of a file that's uploaded to this wiki, you can use a regular internal link. This template is meant for links that directly open or download a file. Linking to a file's File: page can be useful, for instance if you want to show the file's older versions, or to make sure the user sees the licensing conditions.
[[:File:Placeholder.png]]
[[:File:Placeholder.png|Placeholder Image]]
External files
{{Download link|<url>|<description>|<extension>}}
url The full URL.
description description to display instead of the filename.
extension file extension; will be displayed in brackets behind the link.
Examples
⬇️https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.png
{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.png}}
{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.pngg|Placeholder image}}
⬇️Placeholder image (png)
{{Download link|https://tsgdoc.socsci.ru.nl/images/4/47/Placeholder.png|Placeholder image|png}}