Difference between revisions of "Template:Related images"

From Multilingual Bookbinding Dictionary
Jump to navigation Jump to search
(Replaced content with "<noinclude> This is the 'Images' template. It should be called in the following format: <pre> {{Images test |Image= |Imagesize= }} </pre> Edit the page to see the template...")
Tag: Replaced
Line 1: Line 1:
<noinclude>This is the "Image" template used to store and display metadata for uploaded files.
+
<noinclude>
 
+
This is the 'Images' template.
[[Category:Info templates]]
+
It should be called in the following format:
</noinclude><includeonly>{{#ifeq: {{SUBPAGENAME}}
+
<pre>
|{{PAGENAME}}
+
{{Images test
|
+
|Image=
|[[File:{{ROOTPAGENAME}}|1060px|link=File:{{ROOTPAGENAME}}]]
+
|Imagesize=
 
}}
 
}}
=={{int:filedesc}}==
+
</pre>
<table style="width: 100%;"  cellpadding="4">
+
Edit the page to see the template text.
<!-- Existence -->
+
</noinclude><includeonly>
{{#if: {{#show: {{FULLPAGENAME}} |?Media type }}
+
{| border="0" cellpadding="4" cellspacing="4"
|{{#set: Is existing file=true }}
+
! Image
|{{#set: Is existing file=false }}
+
|-
}}
+
! style="text-align: center;" colspan="2" |[[Image:{{{Image|Wiki.png}}}|{{{imagesize|135}}}px]]
 
+
|}
<!-- Description -->
+
</includeonly>
<tr style="vertical-align: top">
 
<td id="fileinfotpl_desc" class="fileinfo-paramfield"><translate><!--T:1--> Description</translate>
 
<td class="description">
 
{{#if: {{{description|{{{Description|}}} }}}
 
|{{#show: {{FULLPAGENAME}} |?Has file description |mainlabel=- |headers=hide }} {{#ifeq: {{SUBPAGENAME}}
 
  |en
 
  |{{{description|{{{Description|}}} }}}
 
  |{{#set: Has file description={{{description|{{{Description|}}} }}}@{{annotatedlanguage: }} }}
 
  }}
 
|<translate><!--T:11--> Description is missing.</translate>
 
}}
 
</td>
 
</tr>
 
 
 
<!-- Caption -->
 
<tr style="vertical-align: top">
 
<td id="fileinfotpl_desc" class="fileinfo-paramfield"><translate><!--T:10--> Caption</translate>
 
<td class="description">
 
{{#if:
 
{{{caption|{{{Caption|}}} }}}
 
|{{#show: {{FULLPAGENAME}} |?Has file caption |mainlabel=- |headers=hide }} {{#ifeq: {{SUBPAGENAME}}
 
  |en
 
  |{{{caption|{{{Caption|}}} }}}
 
  |{{#set: Has file caption={{{caption|{{{Caption|}}} }}}@{{annotatedlanguage: }} }}
 
  }}
 
|<translate><!--T:15--> Caption is missing.</translate>
 
}}
 
</td>
 
</tr>
 
 
 
<!-- Date -->
 
<tr style="vertical-align: top">
 
<td id="fileinfotpl_date" class="fileinfo-paramfield"><translate><!--T:2--> Date</translate></td>
 
<td>{{#if: {{{date|{{{Date|}}} }}}
 
|{{#show: {{FULLPAGENAME}} |?Has file date#-F[Y-m-d] }} {{#set: Has file date={{{date|{{{Date|}}} }}} }}
 
|<translate><!--T:12--> Date is missing.</translate>
 
}}
 
</td>
 
</tr>
 
 
 
<!-- Other fields 1 -->
 
{{{other_fields_1|{{{Other_fields_1|{{{other fields 1|{{{Other fields 1|}}} }}} }}} }}}
 
 
 
<!-- Source -->
 
<tr style="vertical-align: top">
 
<td class="fileinfo-paramfield"><translate><!--T:3--> Source</translate></td>
 
<td>{{#if: {{{source|{{{Source|}}} }}}
 
|{{{source|{{{Source|}}} }}}
 
|<translate><!--T:13--> Source is missing.</translate>
 
}}
 
</td>
 
</tr>
 
 
 
<!-- Author -->
 
<tr style="vertical-align: top">
 
<td class="fileinfo-paramfield"><translate><!--T:4--> Author</translate></td>
 
<td>{{#if: {{{author|{{{Author|}}} }}}
 
|{{{author|{{{Author|}}} }}}
 
|<translate><!--T:14--> Author is missing.</translate>
 
}}
 
</td>
 
</tr>
 
 
 
<!-- License -->
 
{{#if: {{{license |{{{license|}}} }}}{{{licensecode|{{{Licensecode|}}} }}}{{{demo|<noinclude>1</noinclude>}}}
 
|
 
<tr style="vertical-align: top">
 
<td class="fileinfo-paramfield"><translate><!--T:5--> License</translate></td>
 
<td>{{#switch: {{{licensecode|{{{Licensecode|}}} }}}
 
|CC-BY-NC-ND={{{licensecode|{{{Licensecode|}}} }}} {{#set: Has file license=CC-BY-NC-ND }}
 
|CC-BY-NC-SA={{{licensecode|{{{Licensecode|}}} }}} {{#set: Has file license=CC-BY-NC-SA }}
 
|CC-BY-NC={{{licensecode|{{{Licensecode|}}} }}} {{#set: Has file license=CC-BY-NC }}
 
|CC-BY-SA={{{licensecode|{{{Licensecode|}}} }}} {{#set: Has file license=CC-BY-SA }}
 
|CC-BY-ND={{{licensecode|{{{Licensecode|}}} }}} {{#set: Has file license=CC-BY-ND }}
 
|CC-BY={{{licensecode|{{{Licensecode|}}} }}} {{#set: Has file license=CC-BY }}
 
|CC0={{{licensecode|{{{Licensecode|}}} }}} {{#set: Has file license=CC0 }}
 
|C={{{licensecode|{{{Licensecode|}}} }}} {{#set: Has file license=C }}
 
|#default={{#if: {{{license|{{{License|}}} }}}
 
  |{{{license|{{{License|}}} }}}
 
  |<translate><!--T:16--> License is missing.</translate>
 
}}
 
}}{{#if: {{{license|{{{License|}}} }}}
 
|&thinsp;/&thinsp;{{{license|{{{License|}}} }}}
 
|&thinsp;/&thinsp;<translate><!--T:17--> License is missing.</translate>-
 
}}
 
</td>
 
</tr>
 
}}
 
 
 
<!-- Collection-->
 
<tr style="vertical-align: top">
 
<td class="fileinfo-paramfield"><translate><!--T:6--> Collection</translate></td>
 
<td>{{#if: {{{collection|{{{Collection|}}} }}}
 
|{{#set:
 
  |Has image collection={{{collection|{{{Collection|}}} }}}
 
  |+sep=;
 
  |template=SetToUseTemplateForAskQuery
 
  }}
 
|<translate><!--T:18--> Not part of an image collection.</translate>
 
}}
 
</td>
 
</tr>
 
 
 
<!-- Keyword -->
 
<tr style="vertical-align: top">
 
<td class="fileinfo-paramfield"><translate><!--T:7--> Keywords</translate></td>
 
<td>{{#if: {{{keyword|{{{Keyword|}}} }}}
 
|{{#set:
 
  |Has file keyword={{lc: {{{keyword|{{{Keyword|}}} }}} }}
 
  |+sep=;
 
  |template=SetToUseTemplateForAskQuery
 
  }}
 
|<translate><!--T:19--> Keywords are missing.</translate>
 
}}</td>
 
</tr>
 
 
 
<!-- Redirect -->
 
<tr style="vertical-align: top">
 
<td class="fileinfo-paramfield"><translate><!--T:8--> Redirect</translate> {{#info:<translate><!--T:9--> This is the page where the image points to.</translate> }}</td>
 
<td>{{#if: {{{redirect|{{{Redirect|}}} }}}
 
|[[Has redirect::{{{redirect|{{{Redirect|}}} }}}]]
 
|<translate><!--T:20--> Not redirecting to a page.</translate>
 
}}
 
</td>
 
</tr>
 
 
 
<!-- Other fields -->
 
{{{other_fields|{{{Other_fields|{{{other fields|{{{Other fields|}}} }}} }}} }}}
 
 
 
</table> __NOEDITSECTION__
 
[[Category:File{{#translation:}}]]</includeonly>
 

Revision as of 19:35, 22 August 2020

This is the 'Images' template. It should be called in the following format:

{{Images test
|Image=
|Imagesize=
}}

Edit the page to see the template text.