Difference between revisions of "Template:FilmLinks/doc"

From blackwiki
Jump to navigation Jump to search
imported>WOSlinker
(update link after page move)
imported>Zyxw
(update link and add property for BFI)
 
(7 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
{{Documentation subpage}}
 
{{Documentation subpage}}
 +
<!-- Categories go at the bottom of this page and interwikis go in Wikidata. -->
 
{{Uses Wikidata|section=wikidata}}
 
{{Uses Wikidata|section=wikidata}}
<!-- Categories go at the bottom of this page and interwikis go in Wikidata. -->
+
 
 
This template allows linking to external links found on most film title articles. This will aid in the maintenance and standardization of these external links.  
 
This template allows linking to external links found on most film title articles. This will aid in the maintenance and standardization of these external links.  
  
Line 7: Line 8:
 
<includeonly>{{subst only}}</includeonly>
 
<includeonly>{{subst only}}</includeonly>
  
* Not all fields must be used, but do not delete fields when using. An empty field shows a link was considered not worth adding, but a missing link implies the field was forgotten or didn't exist at the time the template was applied.
+
* Not all parameters must be used, but do not delete parameters when using. An empty parameter shows a link was considered not worth adding, but a missing link implies the parameter was forgotten or didn't exist at the time the template was applied.
 
 
 
* Please discuss all proposed additions, deletions and formatting changes to the Template itself within the Template's Talk page.
 
* Please discuss all proposed additions, deletions and formatting changes to the Template itself within the Template's Talk page.
  
===Cut & paste===
+
=== Cut & paste ===
 
Either
 
Either
 
<pre>
 
<pre>
Line 18: Line 18:
 
| imdb            =  
 
| imdb            =  
 
| allmovie        =  
 
| allmovie        =  
| bfidb          =
 
| screen          =
 
| brit            =
 
 
| mojo            =  
 
| mojo            =  
 
| metacritic      =  
 
| metacritic      =  
 
| rotten          =  
 
| rotten          =  
 +
| bfi            =
 +
| screen          =
 +
| brit            =
 
| sony            =  
 
| sony            =  
 
| turner          =  
 
| turner          =  
Line 30: Line 30:
 
or (preferred)
 
or (preferred)
 
<pre>
 
<pre>
{{subst:FilmLinks | name = | imdb = | allmovie = | bfidb = | screen = | brit = | mojo = | metacritic = | rotten = | sony = | turner = }}
+
{{subst:FilmLinks | name = | imdb = | allmovie = | mojo = | metacritic = | rotten = | bfi = | screen = | brit = | sony = | turner = }}
 
</pre>
 
</pre>
The '''order''' of the fields ''does not'' matter.
+
The '''order''' of the parameters ''does not'' matter.
  
===Fields===
+
=== Parameters ===
 
* All parameters are optional, but if you don't include any of them, nothing will show up.
 
* All parameters are optional, but if you don't include any of them, nothing will show up.
 
* Do not use capital letters.  They might disrupt the code.
 
* Do not use capital letters.  They might disrupt the code.
 
{| class=wikitable
 
{| class=wikitable
! Field !! Data !! Result !! [[URL]] source
+
! Parameter !! Data !! Result !! Template !! [[URL]] source
 
|-
 
|-
| ''name'' || text || n/a || name of movie, defaults to [[Help:Magic words#Variables|<nowiki>{{PAGENAME}}</nowiki>]]
+
| ''name'' || text || n/a || n/a || name of movie, defaults to {{tl|PAGENAMEBASE}}
 
|-
 
|-
| ''imdb'' || id || Entry || http://www.imdb.com /title/tt'''[imdb]'''
+
| ''imdb'' || id || Entry || {{tl|IMDb title}} || https://www.imdb.com /title/tt'''[imdb]'''
 
|-
 
|-
| ''allmovie'' || id || Entry || http://www.allmovie.com /movie/v'''[allmovie]'''
+
| ''allmovie'' || id || Entry || {{tl|AllMovie title}} || https://www.allmovie.com /movie/v'''[allmovie]'''
 
|-
 
|-
| ''bfidb'' || id || Entry || http://ftvdb.bfi.org.uk /sift/title/'''[bfidb]'''
+
| ''mojo'' || name || Entry || {{tl|Mojo title}} || https://www.boxofficemojo.com /movies/?id='''[mojo]'''.htm
 
|-
 
|-
| ''screen'' || id || Entry || http://www.screenonline.org.uk /film/id/'''[screen]'''
+
| ''metacritic'' || name || Reviews || {{tl|Metacritic film}} || https://www.metacritic.com /movie/'''[metacritic]'''
 
|-
 
|-
| ''brit'' || id || Entry || http://www.britmovie.co.uk /films/'''[brit]'''
+
| ''rotten'' || name || Reviews || {{tl|Rotten Tomatoes}} || https://www.rottentomatoes.com /m/'''[rotten]'''
 
|-
 
|-
| ''mojo'' || name || Entry || http://www.boxofficemojo.com /movies/?id='''[mojo]'''.htm
+
| ''bfi'' || id || Entry || {{tl|BFI}} || https://www.bfi.org.uk/films-tv-people /'''[bfi]'''
 +
|- style="background-color:lightgrey"
 +
| ''bfidb'' || id || Entry || {{tl|Bfidb title}} || http://www.bfi.org.uk/films-tv-people /sift/title/'''[bfidb]'''
 
|-
 
|-
| ''metacritic'' || name || Reviews || http://www.metacritic.com /movie/'''[metacritic]'''
+
| ''screen'' || id || Entry || {{tl|Screenonline title}} || http://www.screenonline.org.uk /film/id/'''[screen]'''
 
|-
 
|-
| ''rotten'' || name || Reviews || http://www.rottentomatoes.com /m/'''[rotten]'''
+
| ''brit'' || id || Entry || {{tl|Britmovie title}} || http://www.britmovie.co.uk /films/'''[brit]'''
 
|-
 
|-
| ''sony'' || id || Entry || http://www.sonyclassics.com /'''[sony]'''
+
| ''sony'' || id || Entry || n/a<!--{{tl|Sonyclassics title}}--> || http://www.sonyclassics.com /'''[sony]'''
 
|-
 
|-
| ''turner'' || id || Entry || http://tcmdb.com /title/title.jsp?stid='''[turner]'''
+
| ''turner'' || id || Entry || {{tl|TCMDb title}} || http://www.tcm.turner.com/tcmdb /title/title.jsp?stid='''[turner]'''
 
|}
 
|}
  
 
== wikidata ==
 
== wikidata ==
* [[IMDb|Internet Movie Database]] - [[d:Property:P345|P345]]
+
* [[IMDb|Internet Movie Database]] – {{Prop|345|id=f}}
* [[AllMovie]] - [[d:Property:P1562|P1562]]
+
* [[AllMovie]] – {{Prop|1562|id=f}}
* [[Box Office Mojo]] - [[d:Property:P1237|P1237]]
+
* [[Box Office Mojo]] – {{Prop|1237|id=f}}
* [[Metacritic]] - [[d:Property:P1712|P1712]]
+
* [[Metacritic]] – {{Prop|1712|id=f}}
* [[Rotten Tomatoes]] - [[d:Property:P1258|P1258]]
+
* [[Rotten Tomatoes]] – {{Prop|1258|id=f}}
 +
* [[British Film Institute]] – {{Prop|4438|id=f}}
 +
* [[Turner Classic Movies|TCM Movie Database]] – {{Prop|2631|id=f}}
  
==Example==
+
== Examples ==
<code><nowiki>{{subst:FilmLinks | name = Inception | imdb = 1375666 | allmovie = 480818 | bfidb = | screen = | sony = | turner = | mojo = inception | metacritic = inception | rotten = inception}}</nowiki></code>
+
 
<br>will return all relevant external links:
+
=== Example 1 ===
* {{imdb title|1375666|Inception}}
+
<code><nowiki>{{subst:FilmLinks | name = Inception | imdb = 1375666 | allmovie = 480818 | mojo = inception | metacritic = inception | rotten = inception }}</nowiki></code>
 +
 
 +
Adds the following:
 +
<pre>
 +
* {{IMDb title|1375666|Inception}}
 
* {{AllMovie title|480818|Inception}}
 
* {{AllMovie title|480818|Inception}}
 
* {{Mojo title|inception|Inception}}
 
* {{Mojo title|inception|Inception}}
 
* {{Metacritic film|inception|Inception}}
 
* {{Metacritic film|inception|Inception}}
 
* {{Rotten Tomatoes|inception|Inception}}
 
* {{Rotten Tomatoes|inception|Inception}}
 +
</pre>
  
; after subst--
+
Displayed as:
<pre>
+
* {{IMDb title|1375666|Inception}}
* {{imdb title|1375666|Inception}}
 
 
* {{AllMovie title|480818|Inception}}
 
* {{AllMovie title|480818|Inception}}
 
* {{Mojo title|inception|Inception}}
 
* {{Mojo title|inception|Inception}}
 
* {{Metacritic film|inception|Inception}}
 
* {{Metacritic film|inception|Inception}}
 
* {{Rotten Tomatoes|inception|Inception}}
 
* {{Rotten Tomatoes|inception|Inception}}
 +
 +
=== Example 2 ===
 +
<code><nowiki>{{subst:FilmLinks | name = They Drive by Night | imdb = 0030858 | bfi = 4ce2b6b81692c | screen = 502445 | brit = They-Drive-by-Night_1938 }}</nowiki></code>
 +
 +
Adds the following:
 +
<pre>
 +
* {{IMDb title|0030858|They Drive by Night}}
 +
* {{BFI|4ce2b6b81692c|They Drive by Night}}
 +
* {{Screenonline title|502445|They Drive by Night}}
 +
* {{Britmovie title|They-Drive-by-Night_1938|They Drive by Night}}
 
</pre>
 
</pre>
  
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox||
+
Displayed as:
 +
* {{IMDb title|0030858|They Drive by Night}}
 +
* {{BFI|4ce2b6b81692c|They Drive by Night}}
 +
* {{Screenonline title|502445|They Drive by Night}}
 +
* {{Britmovie title|They-Drive-by-Night_1938|They Drive by Night}}
 +
 
 +
=== Example 3 ===
 +
<code><nowiki>{{subst:FilmLinks | name = Midnight in Paris | imdb = 1605783 | sony = midnightinparis | turner = 802334 }}</nowiki></code>
 +
 
 +
Adds the following:
 +
<pre>
 +
* {{IMDb title|1605783|Midnight in Paris}}
 +
* [http://www.sonyclassics.com/midnightinparis ''Midnight in Paris''] at [[Sony Pictures Classics]]
 +
* {{TCMDb title|802334|Midnight in Paris}}
 +
</pre>
 +
 
 +
Displayed as:
 +
* {{IMDb title|1605783|Midnight in Paris}}
 +
* [http://www.sonyclassics.com/midnightinparis ''Midnight in Paris''] at [[Sony Pictures Classics]]
 +
* {{TCMDb title|802334|Midnight in Paris}}
 +
 
 +
<includeonly>{{Sandbox other||
 
<!-- Categories go here and interwikis go in Wikidata. -->
 
<!-- Categories go here and interwikis go in Wikidata. -->
 
[[Category:Television external link templates]]
 
[[Category:Television external link templates]]
 
[[Category:Film external link templates]]
 
[[Category:Film external link templates]]
 +
[[Category:Templates containing multiple external links‎]]
 +
[[Category:External link templates using Wikidata]]
 
}}</includeonly>
 
}}</includeonly>

Latest revision as of 04:00, 15 August 2020

Template:Uses Wikidata

This template allows linking to external links found on most film title articles. This will aid in the maintenance and standardization of these external links.

How to use

  • Not all parameters must be used, but do not delete parameters when using. An empty parameter shows a link was considered not worth adding, but a missing link implies the parameter was forgotten or didn't exist at the time the template was applied.
  • Please discuss all proposed additions, deletions and formatting changes to the Template itself within the Template's Talk page.

Cut & paste

Either

{{subst:FilmLinks
| name            = 
| imdb            = 
| allmovie        = 
| mojo            = 
| metacritic      = 
| rotten          = 
| bfi             = 
| screen          = 
| brit            = 
| sony            = 
| turner          = 
}}

or (preferred)

{{subst:FilmLinks | name = | imdb = | allmovie = | mojo = | metacritic = | rotten = | bfi = | screen = | brit = | sony = | turner = }}

The order of the parameters does not matter.

Parameters

  • All parameters are optional, but if you don't include any of them, nothing will show up.
  • Do not use capital letters. They might disrupt the code.
Parameter Data Result Template URL source
name text n/a n/a name of movie, defaults to {{PAGENAMEBASE}}
imdb id Entry {{IMDb title}} https://www.imdb.com /title/tt[imdb]
allmovie id Entry {{AllMovie title}} https://www.allmovie.com /movie/v[allmovie]
mojo name Entry {{Mojo title}} https://www.boxofficemojo.com /movies/?id=[mojo].htm
metacritic name Reviews {{Metacritic film}} https://www.metacritic.com /movie/[metacritic]
rotten name Reviews {{Rotten Tomatoes}} https://www.rottentomatoes.com /m/[rotten]
bfi id Entry {{BFI}} https://www.bfi.org.uk/films-tv-people /[bfi]
bfidb id Entry {{Bfidb title}} http://www.bfi.org.uk/films-tv-people /sift/title/[bfidb]
screen id Entry {{Screenonline title}} http://www.screenonline.org.uk /film/id/[screen]
brit id Entry {{Britmovie title}} http://www.britmovie.co.uk /films/[brit]
sony id Entry n/a http://www.sonyclassics.com /[sony]
turner id Entry {{TCMDb title}} http://www.tcm.turner.com/tcmdb /title/title.jsp?stid=[turner]

wikidata

Examples

Example 1

{{subst:FilmLinks | name = Inception | imdb = 1375666 | allmovie = 480818 | mojo = inception | metacritic = inception | rotten = inception }}

Adds the following:

* {{IMDb title|1375666|Inception}}
* {{AllMovie title|480818|Inception}}
* {{Mojo title|inception|Inception}}
* {{Metacritic film|inception|Inception}}
* {{Rotten Tomatoes|inception|Inception}}

Displayed as:

Example 2

{{subst:FilmLinks | name = They Drive by Night | imdb = 0030858 | bfi = 4ce2b6b81692c | screen = 502445 | brit = They-Drive-by-Night_1938 }}

Adds the following:

* {{IMDb title|0030858|They Drive by Night}}
* {{BFI|4ce2b6b81692c|They Drive by Night}}
* {{Screenonline title|502445|They Drive by Night}}
* {{Britmovie title|They-Drive-by-Night_1938|They Drive by Night}}

Displayed as:

Example 3

{{subst:FilmLinks | name = Midnight in Paris | imdb = 1605783 | sony = midnightinparis | turner = 802334 }}

Adds the following:

* {{IMDb title|1605783|Midnight in Paris}}
* [http://www.sonyclassics.com/midnightinparis ''Midnight in Paris''] at [[Sony Pictures Classics]]
* {{TCMDb title|802334|Midnight in Paris}}

Displayed as: