Difference between revisions of "Template:FIFA player/doc"

From blackwiki
Jump to navigation Jump to search
imported>Zyxw
(add new URL)
imported>Vanisaac
m (→‎See also: clean up per WP:CAT#T and WP:AWBREQ add template:Sandbox other)
 
(3 intermediate revisions by 2 users not shown)
Line 16: Line 16:
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= ''ID'' }}</code>
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= ''ID'' }}</code>
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= ''ID'' | name= ''NAME'' }}</code>
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= ''ID'' | name= ''NAME'' }}</code>
 +
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= ''ID'' | archive= ''NUMBER'' }}</code>
 +
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= ''ID'' | name= ''NAME'' | archive= ''NUMBER'' }}</code>
  
 
Using [[Wikidata]] property {{Property|1469}}:
 
Using [[Wikidata]] property {{Property|1469}}:
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}}<nowiki>}}</nowiki></code>
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}}<nowiki>}}</nowiki></code>
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | name= ''NAME'' }}</code>
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | name= ''NAME'' }}</code>
 +
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | archive= ''NUMBER'' }}</code>
 +
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | name= ''NAME'' | archive= ''NUMBER'' }}</code>
  
 
== Examples ==
 
== Examples ==
Line 26: Line 30:
  
 
''Usage:''
 
''Usage:''
−
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | 63869 | PELÉ (Edson Arantes do Nascimento) }}</code>
+
: <code><nowiki>* {{</nowiki>{{BASEPAGENAME}} | 63869 | PELÉ (Edson Arantes do Nascimento) }}</code>
  
 
''Output:''
 
''Output:''
−
: {{{{BASEPAGENAME}} | 63869 | PELÉ (Edson Arantes do Nascimento) }}
+
:* {{{{BASEPAGENAME}} | 63869 | PELÉ (Edson Arantes do Nascimento) }}
  
−
''Current URL:''
+
''Current URLs:''
−
: <kbd>[https://www.fifa.com/worldcup/players/player/63869/ https://www.fifa.com/worldcup/players/player/{{hilite|63869}}/]</kbd>
+
: [https://static.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html https://static.fifa.com/fifa-tournaments/players-coaches/people={{hilite|63869}}/index.html]
 +
: [https://www.fifa.com/worldcup/players/player/63869/ https://www.fifa.com/worldcup/players/player/{{hilite|63869}}/]
  
 
''Former URL:''
 
''Former URL:''
−
: <kbd>[https://www.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html https://www.fifa.com/fifa-tournaments/players-coaches/people={{hilite|63869}}/index.html]</kbd>
+
: [https://www.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html https://www.fifa.com/fifa-tournaments/players-coaches/people={{hilite|63869}}/index.html] ([https://web.archive.org/web/20150905215836/http://www.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html archive])
  
 
=== Named parameters ===
 
=== Named parameters ===
 
''Usage:''
 
''Usage:''
−
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= 284 | name= Brandi CHASTAIN }}</code>
+
: <code><nowiki>* {{</nowiki>{{BASEPAGENAME}} | id= 284 | name= Brandi CHASTAIN }}</code>
 +
: <code><nowiki>* {{</nowiki>{{BASEPAGENAME}} | id= 284 | name= Brandi CHASTAIN | archive= 20160305161836 }}</code>
  
 
''Output:''
 
''Output:''
−
: {{{{BASEPAGENAME}} | id= 284 | name= Brandi CHASTAIN }}
+
:* {{{{BASEPAGENAME}} | id= 284 | name= Brandi CHASTAIN }}
 +
:* {{{{BASEPAGENAME}} | id= 284 | name= Brandi CHASTAIN | archive= 20160305161836 }}
  
−
''Current URL:''
+
''Current URLs:''
−
: <kbd>[https://www.fifa.com/worldcup/players/player/284/ https://www.fifa.com/worldcup/players/player/{{hilite|284}}/]</kbd>
+
: [https://static.fifa.com/fifa-tournaments/players-coaches/people=284/index.html https://static.fifa.com/fifa-tournaments/players-coaches/people={{hilite|284}}/index.html]
 +
: [https://www.fifa.com/worldcup/players/player/284/ https://www.fifa.com/worldcup/players/player/{{hilite|284}}/]
  
 
''Former URL:''
 
''Former URL:''
−
: <kbd>[https://www.fifa.com/fifa-tournaments/players-coaches/people=284/index.html https://www.fifa.com/fifa-tournaments/players-coaches/people={{hilite|284}}/index.html]</kbd>
+
: [https://www.fifa.com/fifa-tournaments/players-coaches/people=284/index.html https://www.fifa.com/fifa-tournaments/players-coaches/people={{hilite|284}}/index.html] ([https://web.archive.org/web/20160305161836/https://www.fifa.com/fifa-tournaments/players-coaches/people=284/index.html archive])
  
 
=== No parameters and Wikidata property not defined ===
 
=== No parameters and Wikidata property not defined ===
 
''Usage:''
 
''Usage:''
−
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}}<nowiki>}}</nowiki></code>
+
: <code><nowiki>* {{</nowiki>{{BASEPAGENAME}}<nowiki>}}</nowiki></code>
  
 
''Output:''
 
''Output:''
−
: {{ {{BASEPAGENAME}} }}
+
:* {{ {{BASEPAGENAME}} }}
  
 
== TemplateData ==
 
== TemplateData ==
Line 66: Line 74:
 
       "label": "FIFA.com player ID",
 
       "label": "FIFA.com player ID",
 
       "aliases": ["1"],  
 
       "aliases": ["1"],  
−
       "description": "The \"id\" parameter (or unnamed parameter \"1\") should contain the ID portion of the URL. Example: 63869 is the ID portion of https://www.fifa.com/worldcup/players/player/63869/ or https://www.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html. This parameter is optional if Wikidata property P1469 exists, but required if not.",
+
       "description": "The \"id\" parameter (or unnamed parameter \"1\") should contain the ID portion of the URL. Example: 63869 is the ID portion of https://static.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html or https://www.fifa.com/worldcup/players/player/63869/. This parameter is optional if Wikidata property P1469 exists, but required if not.",
 
       "type": "number",
 
       "type": "number",
 
       "required": false,
 
       "required": false,
Line 78: Line 86:
 
       "required": false,
 
       "required": false,
 
       "default": "{{PAGENAMEBASE}}"
 
       "default": "{{PAGENAMEBASE}}"
 +
    },
 +
    "archive": {
 +
      "label": "archive",
 +
      "description": "Number representing the date/time in an Internet Archive URL, such as 20150905215836 in https://web.archive.org/web/20150905215836/http://www.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html.",
 +
      "type": "number",
 +
      "required": false
 
     }
 
     }
 
   },
 
   },
 
   "paramOrder": [
 
   "paramOrder": [
 
     "id",
 
     "id",
−
     "name"
+
     "name",
 +
    "archive"
 
   ]
 
   ]
 
}
 
}
Line 88: Line 103:
  
 
== Tracking categories ==
 
== Tracking categories ==
−
; "id" parameter exists
+
; template with ID
−
* {{clc|FIFA player ID same as Wikidata}}
 
 
* {{clc|FIFA player ID different from Wikidata}}
 
* {{clc|FIFA player ID different from Wikidata}}
 
* {{clc|FIFA player ID not in Wikidata}}
 
* {{clc|FIFA player ID not in Wikidata}}
−
; "id" parameter does not exist
+
; template missing ID
−
* {{clc|FIFA player template using Wikidata}}
 
 
* {{clc|FIFA player template missing ID}}
 
* {{clc|FIFA player template missing ID}}
  
 
== See also ==
 
== See also ==
 
* {{tl|UEFA player}}
 
* {{tl|UEFA player}}
 +
* {{tl|AFC player}}
 
* {{tl|NFT player}}
 
* {{tl|NFT player}}
 
* {{tl|Soccerbase}}
 
* {{tl|Soccerbase}}
 
* {{tl|Soccerway}}
 
* {{tl|Soccerway}}
  
−
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox||
+
<includeonly>{{Sandbox other||
 
<!-- Categories go here, and interwikis go in Wikidata -->
 
<!-- Categories go here, and interwikis go in Wikidata -->
 
[[Category:Association football external link templates|FIFA player]]
 
[[Category:Association football external link templates|FIFA player]]
Line 108: Line 122:
 
[[Category:Sports governing body external link templates]]
 
[[Category:Sports governing body external link templates]]
 
[[Category:External link templates using Wikidata]]
 
[[Category:External link templates using Wikidata]]
 +
[[Category:External link templates with archive parameter]]
 
[[Category:Templates that add a tracking category]]
 
[[Category:Templates that add a tracking category]]
 
}}</includeonly>
 
}}</includeonly>

Latest revision as of 04:39, 25 April 2020

Template:Uses Wikidata Template:Tracks Wikidata

Template:FIFA player displays an external link to an association football (soccer) player's profile at FIFA.com, the official website of the International Federation of Association Football (FIFA: Fédération Internationale de Football Association). It is intended for use in the external links section of an article.

Usage

Unnamed parameters:

{{FIFA player | ID }}
{{FIFA player | ID | NAME }}

Named parameters:

{{FIFA player | id= ID }}
{{FIFA player | id= ID | name= NAME }}
{{FIFA player | id= ID | archive= NUMBER }}
{{FIFA player | id= ID | name= NAME | archive= NUMBER }}

Using Wikidata property Template:Property:

{{FIFA player}}
{{FIFA player | name= NAME }}
{{FIFA player | archive= NUMBER }}
{{FIFA player | name= NAME | archive= NUMBER }}

Examples

Unnamed parameters

Usage:

* {{FIFA player | 63869 | PELÉ (Edson Arantes do Nascimento) }}

Output:

Current URLs:

https://static.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html
https://www.fifa.com/worldcup/players/player/63869/

Former URL:

https://www.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html (archive)

Named parameters

Usage:

* {{FIFA player | id= 284 | name= Brandi CHASTAIN }}
* {{FIFA player | id= 284 | name= Brandi CHASTAIN | archive= 20160305161836 }}

Output:

Current URLs:

https://static.fifa.com/fifa-tournaments/players-coaches/people=284/index.html
https://www.fifa.com/worldcup/players/player/284/

Former URL:

https://www.fifa.com/fifa-tournaments/players-coaches/people=284/index.html (archive)

No parameters and Wikidata property not defined

Usage:

* {{FIFA player}}

Output:

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.

TemplateData for FIFA player

This template displays an external link to an association football (soccer) player's profile at FIFA.com, the official website of the International Federation of Association Football (FIFA: Fédération Internationale de Football Association). It is intended for use in the external links section of an article.

Template parameters

ParameterDescriptionTypeStatus
FIFA.com player IDid 1

The "id" parameter (or unnamed parameter "1") should contain the ID portion of the URL. Example: 63869 is the ID portion of https://static.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html or https://www.fifa.com/worldcup/players/player/63869/. This parameter is optional if Wikidata property P1469 exists, but required if not.

Default
Wikidata property P1469
Numberoptional
Player namename 2

The "name" parameter (or unnamed parameter "2") may be used to specify the link text, which should be the name of the player. This parameter is optional; it defaults to the Wikipedia article name, without any disambiguation such as "(footballer)" or "(soccer)".

Default
{{PAGENAMEBASE}}
Stringoptional
archivearchive

Number representing the date/time in an Internet Archive URL, such as 20150905215836 in https://web.archive.org/web/20150905215836/http://www.fifa.com/fifa-tournaments/players-coaches/people=63869/index.html.

Numberoptional

Tracking categories

template with ID
template missing ID

See also