Template:Extracted from/doc: Difference between revisions

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search
Content deleted Content added
Sarang (talk | contribs)
m format
FeRDNYC (talk | contribs)
Move examples to separate sections following Template:TemplateBox (as in Template:Information/doc). They don't format properly within the TemplateBox code
Line 38: Line 38:
|usage-notes =
|usage-notes =
|type =marker
|type =marker
|example = 
|example =LA2-NSRW-1-0007.jpg
|example-value =
*{{tlx|Extracted from|LA2-NSRW-1-0007.jpg}} -> {{Extracted from|LA2-NSRW-1-0007.jpg}}
*{{tlx|Extracted from|File:LA2-NSRW-1-0007.jpg}} -> {{Extracted from|File:LA2-NSRW-1-0007.jpg}}
*{{tlx|Extracted from|Image:LA2-NSRW-1-0007.jpg}} -> {{Extracted from|Image:LA2-NSRW-1-0007.jpg}}
*{{tlx|Extracted from|Media:LA2-NSRW-1-0007.jpg|3=by=LA2}} -> {{Extracted from|Media:LA2-NSRW-1-0007.jpg|by=LA2}}
*{{tlx|Extracted from|LA2-NSRW-1-0007.jpg|3=wikitext}} -> {{Extracted from|LA2-NSRW-1-0007.jpg|wikitext}}
*{{tlx|Extracted from|LA2-NSRW-1-0007.jpg|4=3=wikitext}} -> {{Extracted from|LA2-NSRW-1-0007.jpg|3=wikitext}}
*{{tlx|Extracted from|LA2-NSRW-1-0007.jpg|3=2nd|4=3rd}} -> {{Extracted from|LA2-NSRW-1-0007.jpg|2nd|3rd}}
*<nowiki>{{Extracted from|LA2-NSRW-1-0007.jpg|3=}}</nowiki> -> {{Extracted from|LA2-NSRW-1-0007.jpg|3=}}
|i18n-method =autotranslate
|i18n-method =autotranslate
|i18n-desc =The 3 parameters "1", "2" and "3" MUST be defined in the language subpages, see how in the source code of {{tlx|Extracted from/en}} for example.
|i18n-desc =The 3 parameters "1", "2" and "3" MUST be defined in the language subpages, see how in the source code of {{tlx|Extracted from/en}} for example.
Line 66: Line 57:
|relieson =
|relieson =
|mustbesubst =
|mustbesubst =
}}
}}<includeonly>
==More examples==
===File namespace example===
{{pre2|scroll|<nowiki>
{{Extracted from|File:LA2-NSRW-1-0007.jpg}}
</nowiki>}}
Produces:
{{Extracted from|File:LA2-NSRW-1-0007.jpg}}

===Image namespace example===
{{pre2|scroll|<nowiki>
{{Extracted from|Image:LA2-NSRW-1-0007.jpg}}
</nowiki>}}
Produces:
{{Extracted from|Image:LA2-NSRW-1-0007.jpg}}

===Media namespace example with by= named argument===
{{pre2|scroll|<nowiki>
{{Extracted from|Media:LA2-NSRW-1-0007.jpg|by=LA2}}
</nowiki>}}
Produces:
{{Extracted from|Media:LA2-NSRW-1-0007.jpg|by=LA2}}

===Example with wikitext argument===
{{pre2|scroll|<nowiki>
{{Extracted from|LA2-NSRW-1-0007.jpg|wikitext}}
</nowiki>}}
Produces:
{{Extracted from|LA2-NSRW-1-0007.jpg|wikitext}}

===Example with explicit third unnamed argument===
{{pre2|scroll|<nowiki>
{{Extracted from|LA2-NSRW-1-0007.jpg|3=wikitext}}
</nowiki>}}
Produces:
{{Extracted from|LA2-NSRW-1-0007.jpg|3=wikitext}}

===Example with second and third unnamed arguments===
{{pre2|scroll|<nowiki>
{{Extracted from|LA2-NSRW-1-0007.jpg|2nd|3rd}}
</nowiki>}}
Produces:
{{Extracted from|LA2-NSRW-1-0007.jpg|2nd|3rd}}
===Example with blank unnamed third argument===
{{pre2|scroll|<nowiki>
{{Extracted from|LA2-NSRW-1-0007.jpg|3=}}
</nowiki>}}
Produces:
{{Extracted from|LA2-NSRW-1-0007.jpg|3=}}
<includeonly>
[[Category:Marker templates|ExtractedFrom]]
[[Category:Marker templates|ExtractedFrom]]
</includeonly>
</includeonly>

Revision as of 14:03, 13 September 2019

Display the source of an extracted, e.g., cropped, file.

The template automatically sets the following categories: Extracted images
(or Extracted images with broken file links)

Usage

{{Extracted from |1= }}

Or use the shorthand

{{Ef}}, {{Cropped}}

Template parameters

ParameterDescriptionDefaultStatus
1SourceSource file (optional with namespace)emptyrequired
2CommentComment (instead of bot parameters)emptyoptional
3NoThumbWikitext replacing the source thumbnailemptyoptional
botUserBot userOnly used for Cropbot if parameter 2 is emptyemptyoptional
botUserCommentBot user commentOnly used for Cropbot if parameter 2 is emptyemptyoptional
byOriginal authorUser who created the source fileemptyoptional

Additional information

The template is intended to be used in the following namespaces: the File namespace

The template is intended to be used by the following user groups: all users

Placement: In the "Source" parameter of the {{Information}} template (or the respective parameter of similar templates) or just below this template

Example

{{Extracted from|LA2-NSRW-1-0007.jpg}}

renders as:

image extraction process
This file has been extracted from another file
: LA2-NSRW-1-0007.jpg
original file

See also

Localization

čeština  Deutsch  eesti  English  español  Esperanto  euskara  suomi  français  galego  hrvatski  Bahasa Indonesia  italiano  Lëtzebuergesch  magyar  Nederlands  polski  português  português do Brasil  română  slovenčina  slovenščina  svenska  Türkçe  tiếng Việt  Ελληνικά  қазақша  македонски  нохчийн  русский  українська  বাংলা  മലയാളം  ไทย  한국어  日本語  中文  中文(简体)  中文(繁體)  עברית  اردو  العربية  فارسی  +/−

This template is localized through {{Autotranslate}}. The layout of the template can be found under Template:Extracted from/layout.

To add your language to the list of languages supported by this template, please copy the code of Template:Extracted from/en (or any other language version you prefer to translate) and replace the text strings in there (the form below can be used to create a translation, the English version is preloaded in the edit box). Please change the parameter lang from en (or whatever language you are translating) to the language code of your language.


The 3 parameters "1", "2" and "3" MUST be defined in the language subpages, see how in the source code of {{Extracted from/en}} for example.

More examples

File namespace example

{{Extracted from|File:LA2-NSRW-1-0007.jpg}}

Produces:

image extraction process
This file has been extracted from another file
: LA2-NSRW-1-0007.jpg
original file

Image namespace example

{{Extracted from|Image:LA2-NSRW-1-0007.jpg}}

Produces:

image extraction process
This file has been extracted from another file
: LA2-NSRW-1-0007.jpg
original file

Media namespace example with by= named argument

{{Extracted from|Media:LA2-NSRW-1-0007.jpg|by=LA2}}

Produces:

image extraction process
This file has been extracted from another file
: LA2-NSRW-1-0007.jpg by LA2
original file

Example with wikitext argument

{{Extracted from|LA2-NSRW-1-0007.jpg|wikitext}}

Produces:

image extraction process
This file has been extracted from another file
: LA2-NSRW-1-0007.jpg
wikitext
original file

Example with explicit third unnamed argument

{{Extracted from|LA2-NSRW-1-0007.jpg|3=wikitext}}

Produces:

image extraction process
This file has been extracted from another file
: LA2-NSRW-1-0007.jpg
wikitext

Example with second and third unnamed arguments

{{Extracted from|LA2-NSRW-1-0007.jpg|2nd|3rd}}

Produces:

image extraction process
This file has been extracted from another file
: LA2-NSRW-1-0007.jpg
2nd
3rd

Example with blank unnamed third argument

{{Extracted from|LA2-NSRW-1-0007.jpg|3=}}

Produces:

image extraction process
This file has been extracted from another file
: LA2-NSRW-1-0007.jpg
original file