Jump to content

Template:Football season player stats/doc

From Wikipedia, the free encyclopedia

Parameters

[edit]

All parameters are optional, but date and country are highly recommended.

  • country: The three letter FIFA country code of the country that the club plays in. For instance, for a club playing in English competitions, enter ENG.
  • date: Date for which the statistics are correct. Enter the date into this parameter exactly as you wish that date to be displayed. For instance, |date=26 December 2009 produces

Correct as of 26 December 2009.

  • number: If set, this parameter adds a column for player squad numbers. If the parameter is left blank, the column will not appear.
  • cup2: If set, this parameter adds columns for appearances and goals in a country's second cup competition, where applicable. If left blank, the columns will not appear.
  • continent: If set, this parameter adds columns for appearances and goals in continental competition(s), where applicable. If left blank, the columns will not appear.
  • playoff: If set, this parameter adds columns for appearances and goals if the club participates in a playoff system. If left blank, the columns will not appear.
  • other: This optional parameter should only be used for appearances in competitions not covered by any of the above, for instance the Community Shield or Football League Trophy in England. If set, it adds columns for appearances and goals in "other" competitions. If left blank, the columns will not appear.
  • nopics: If set, this parameter will remove the colours from the key, and replace A yellow card and A red card with Y and R respectively. If left blank, the colour and images will be used.
  • nosubs: This optional parameter should be used if you do not intend to differentiate between starting appearances and substitute appearances. Setting this parameter will remove the line "Starting appearances are listed first, followed by substitute appearances in parentheses where applicable."
  • nokey: set this parameter to disable the key altogether. Not recommended unless you intend to use an alternative key.

Sample output

[edit]
{{football season player stats
|number=yes
|country=ENG
|continent=yes
|playoff=yes
|other=yes
|cup2=yes
|nopics=yes
|date=26 December 2009
}}
<!-- Player data goes here -->
|}

Produces:

Key:
  ‡ On loan from another club   * First appearance(s) for the club

Correct as of 26 December 2009. Starting appearances are listed first, followed by substitute appearances in parentheses where applicable.

No.PosNamePGPGPGPGPGPGPG Y R Notes
League FA CupLeague CupPlayoffsEuropeOtherTotalDiscipline
{{football season player stats
|country=SCO
|continent=
|playoff=
|other=
|cup2=yes
|nopics=
|date=December 26 2009
}}
<!--Player data goes here -->
|}

Produces:

Key:
  ‡ On loan from another club   * First appearance(s) for the club

Correct as of December 26, 2009. Starting appearances are listed first, followed by substitute appearances in parentheses where applicable.

PosNamePGPGPGPG A yellow card A red card Notes
League Scottish CupScottish League CupTotalDiscipline

Sorting

[edit]

Names

[edit]

To sort players by their surnames, use {{sortname}}. Here are a few examples:

  • Players whose name is their Wikipedia article, such as Scott Loach, would be entered as

{{sortname|Scott|Loach}}

{{sortname|Don|Cowie|Don Cowie (footballer)}}

  • Players who do not have a Wikipedia article, such as Your Cat, can be redlinked with

{{sortname|Your|Cat}}

Alternatively, you may choose not to link them at all, by entering {{sortname|Your|Cat|nolink=1}}

Numbers between one and nine

[edit]

If a single-digit number does not sort correctly, use {{sort}}. For example, if a player has scored 4 goals, but the table sorts him above someone who has scored 23 goals, use {{sort|04|4}}.

Substitute appearances

[edit]

To sort players who have made substitute appearances correctly, you will need to use {{sort}}. If a player has started five matches, and made three further substitute appearances, we want the sort function to know he has played eight games. This can be achieved by entering: {{sort|08|5(3)}}

which will display 5(3), but sort correctly.

Advanced sorting ("cheating")

[edit]

If you want to ensure that players who have played the same number of games but have made more starts sort higher, you will need to "cheat" using {{sort}}. For example, Player A has started 14 games and made 3 sub appearances, Player B has started 17 games, and Player C has started 2 and made 15 sub appearances. The sort key can be used like this:

|-
|Player A||{{sort|17|14(3)}}
|-
|Player B||{{sort|17.1|17}}
|-
|Player C||{{sort|16.9|2(15)}}
|-
|}

Creating a table that sorts like this:

Name Games played
Player A 14(3)
Player B 17
Player C 2(15)

Demonstration

[edit]

This real-life example data is based on Watford statistics prior to their fixture on 26 December 2009, and brings together all of the concepts explained in this documentation.

Expand to see raw data
{{football season player stats|number=yes|country=ENG|cup2=yes|date=26 December 2009}}
|-
| style="text-align:left;" |{{sort|01|1}}|| style="text-align:left;" |GK|| style="text-align:left;" |{{sortname|Scott|Loach}}
|22||0||0||0||0||0||22||0||1||0||
|-
| style="text-align:left;" |{{sort|02|2}}|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Adrian|Mariappa}}
|22||1||0||0||2||0||24||1||4||0||
|-
| style="text-align:left;" |{{sort|03|3}}|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Jure|Travner}}
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |{{sort|04|4}}|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Scott|Severin}}
|{{sort|08.5|4(5)}}||0||0||0||1||1||style="background:#98FB98"|{{sort|09.5|5(5)*}}||1||0||0||
|-
| style="text-align:left;" |{{sort|05|5}}|| style="text-align:left;" |MF||style="background:#faecc8" align="left"|{{sortname|Henri|Lansbury}}‡
|{{sort|16.5|14(3)}}||2||0||0||{{sort|0.5|0(1)}}||0||style="background:#98FB98"|{{sort|17.5|14(4)}}*||2||2||0||
|-
| style="text-align:left;" |{{sort|06|6}}|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Jay|DeMerit}}
|{{sort|07.5|7(1)}}||0||0||0||0||0||{{sort|07.5|7(1)}}||0||0||0||
|-
| style="text-align:left;" |{{sort|07|7}}|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Don|Cowie|Don Cowie (footballer)}}
|18||1||0||0||2||0||20||1||0||0||
|-
| style="text-align:left;" |{{sort|08|8}}|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Tommy|Smith|Tommy Smith (footballer, born 1980)}}†
|{{sort|04|4}}||2||0||0||1||0||5||2||0||0||
|-
| style="text-align:left;" |{{sort|09|9}}|| style="text-align:left;" |FW|| style="text-align:left;" |{{sortname|Tamás|Priskin}}†
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |10|| style="text-align:left;" |FW|| style="text-align:left;" |{{sortname|Danny|Graham|Danny Graham (footballer)}}
|22||7||0||0||2||0||style="background:#98FB98"|24*||7||2||0||
|-
| style="text-align:left;" |11|| style="text-align:left;" |FW||style="background:#faecc8" align="left"|{{sortname|Heiðar|Helguson}}‡
|{{sort|07.5|6(2)}}||5||0||0||0||0||{{sort|07.5|6(2)}}||5||2||0||
|-
| style="text-align:left;" |11|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Jobi|McAnuff}}†
|{{sort|03|3}}||0||0||0||1||0||4||0||0||0||
|-
| style="text-align:left;" |12|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Lloyd|Doyley}}
|22||1||0||0||2||0||24||1||2||0||
|-
| style="text-align:left;" |13|| style="text-align:left;" |GK|| style="text-align:left;" |{{sortname|Jonathan|North|nolink=1}}
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |14|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Ross|Jenkins|Ross Jenkins (footballer, born 1990)}}
|13||0||0||0||1||0||14||0||1||0||
|-
| style="text-align:left;" |15|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Jon|Harley}}
|{{sort|19.5|9(11)}}||1||0||0||{{sort|0.5|0(1)}}||0||{{sort|20.5|9(12)}}||1||3||0||
|-
| style="text-align:left;" |16|| style="text-align:left;" |GK|| style="text-align:left;" |{{sortname|Richard|Lee|Richard Lee (footballer)}}
|0||0||0||0||2||0||2||0||0||0||
|-
| style="text-align:left;" |17|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Dale|Bennett}}
|{{sort|03|3}}||0||0||0||0||0||3||0||1||0||
|-
| style="text-align:left;" |18|| style="text-align:left;" |FW|| style="text-align:left;" |{{sortname|Will|Hoskins}}
|{{sort|05.5|2(4)}}||1||0||0||1||0||{{sort|6.5|3(4)}}||0||0||0||
|-
| style="text-align:left;" |19|| style="text-align:left;" |FW|| style="text-align:left;" |{{sortname|Liam|Henderson|Liam Henderson (footballer, born 1989)}}
|{{sort|05.1|0(6)}}||0||0||0||{{sort|0.5|0(1)}}||0||{{sort|06.1|0(7)}}||0||0||0||
|-
| style="text-align:left;" |20|| style="text-align:left;" |MF||style="background:#faecc8" align="left"|{{sortname|Tom|Cleverley}}‡
|{{sort|19|19}}||7||0||0||{{sort|01|1}}||0||style="background:#98FB98"|20*||7||3||0||
|-
| style="text-align:left;" |21|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Lewis|Young}}
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |22|| style="text-align:left;" |DF||style="background:#faecc8" align="left"|{{sortname|Craig|Cathcart}}‡
|{{sort|12|12}}||0||0||0||0||0||style="background:#98FB98"|12*||0||0||0||
|-
| style="text-align:left;" |23|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Jordan|Parkes}}
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |24|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Mike|Williamson|Mike Williamson (footballer)}}†
|{{sort|04|4}}||1||0||0||{{sort|02|2}}||1||6||2||0||0||
|-
| style="text-align:left;" |25|| style="text-align:left;" |FW|| style="text-align:left;" |{{sortname|Nathan|Ellington}}¤
|{{sort|16.1|2(15)}}||1||0||0||{{sort|0.5|0(1)}}||0||{{sort|17.1|2(16)}}||1||2||1||<nowiki><ref></nowiki>
|-
| style="text-align:left;" |26|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|John-Joe|O'Toole}}¤
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |27|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Mat|Sadler}}
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |28|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|John|Eustace}}
|{{sort|17.5|15(3)}}||0||0||0||{{sort|2|2}}||0||{{sort|19.5|17(3)}}||1||2||0||
|-
| style="text-align:left;" |29|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Michael|Bryan|Michael Bryan (footballer)}}
|{{sort|02.1|0(3)}}||0||0||0||0||0||style="background:#98FB98"|{{sort|02.5|0(3)*}}||0||0||0||
|-
| style="text-align:left;" |30|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Rob|Kiernan}}
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |31|| style="text-align:left;" |FW|| style="text-align:left;" |{{sortname|Marvin|Sordell}}
|{{sort|02.5|1(2)}}||0||0||0||{{sort|0.5|0(1)}}||1||style="background:#98FB98"|{{sort|03.4|1(3)*}}||1||1||0||
|-
| style="text-align:left;" |32|| style="text-align:left;" |MF|| style="text-align:left;" |{{sortname|Billy|Gibson|Billy Gibson (English footballer)}}¤
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |33|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Lee|Hodson}}
|18||0||0||0||{{sort|02|2}}||0||20||0||2||0||
|-
| style="text-align:left;" |34|| style="text-align:left;" |DF|| style="text-align:left;" |{{sortname|Eddie|Oshodi}}
|{{sort|01|0(1)}}||0||0||0||0||0||style="background:#98FB98"|{{sort|01|0(1)*}}||0||0||0||
|-
| style="text-align:left;" |35|| style="text-align:left;" |GK|| style="text-align:left;" |{{sortname|Bo|Antal|nolink=1}}
|0||0||0||0||0||0||0||0||0||0||
|-
| style="text-align:left;" |36|| style="text-align:left;" |FW|| style="text-align:left;" |{{sortname|Kurtney|Brooks}}
|0||0||0||0||{{sort|0.5|0(1)}}||0||style="background:#98FB98"|{{sort|01|0(1)*}}||0||0||0||
|-
| style="text-align:left;" |37|| style="text-align:left;" |GK|| style="text-align:left;" |{{sortname|Jonathan|Bond|nolink=1}}
|0||0||0||0||0||0||0||0||0||0||
|}

Output:

Key:
  ‡ On loan from another club   * First appearance(s) for the club

Correct as of 26 December 2009. Starting appearances are listed first, followed by substitute appearances in parentheses where applicable.

No.PosNamePGPGPGPG A yellow card A red card Notes
League FA CupLeague CupTotalDiscipline
1 GK Scott Loach 22 0 0 0 0 0 22 0 1 0
2 DF Adrian Mariappa 22 1 0 0 2 0 24 1 4 0
3 DF Jure Travner 0 0 0 0 0 0 0 0 0 0
4 MF Scott Severin 4(5) 0 0 0 1 1 5(5)* 1 0 0
5 MF Henri Lansbury 14(3) 2 0 0 0(1) 0 14(4)* 2 2 0
6 DF Jay DeMerit 7(1) 0 0 0 0 0 7(1) 0 0 0
7 MF Don Cowie 18 1 0 0 2 0 20 1 0 0
8 MF Tommy Smith 4 2 0 0 1 0 5 2 0 0
9 FW Tamás Priskin 0 0 0 0 0 0 0 0 0 0
10 FW Danny Graham 22 7 0 0 2 0 24* 7 2 0
11 FW Heiðar Helguson 6(2) 5 0 0 0 0 6(2) 5 2 0
11 MF Jobi McAnuff 3 0 0 0 1 0 4 0 0 0
12 DF Lloyd Doyley 22 1 0 0 2 0 24 1 2 0
13 GK Jonathan North 0 0 0 0 0 0 0 0 0 0
14 MF Ross Jenkins 13 0 0 0 1 0 14 0 1 0
15 MF Jon Harley 9(11) 1 0 0 0(1) 0 9(12) 1 3 0
16 GK Richard Lee 0 0 0 0 2 0 2 0 0 0
17 DF Dale Bennett 3 0 0 0 0 0 3 0 1 0
18 FW Will Hoskins 2(4) 1 0 0 1 0 3(4) 0 0 0
19 FW Liam Henderson 0(6) 0 0 0 0(1) 0 0(7) 0 0 0
20 MF Tom Cleverley 19 7 0 0 1 0 20* 7 3 0
21 MF Lewis Young 0 0 0 0 0 0 0 0 0 0
22 DF Craig Cathcart 12 0 0 0 0 0 12* 0 0 0
23 DF Jordan Parkes 0 0 0 0 0 0 0 0 0 0
24 DF Mike Williamson 4 1 0 0 2 1 6 2 0 0
25 FW Nathan Ellington¤ 2(15) 1 0 0 0(1) 0 2(16) 1 2 1 <ref>
26 MF John-Joe O'Toole¤ 0 0 0 0 0 0 0 0 0 0
27 DF Mat Sadler 0 0 0 0 0 0 0 0 0 0
28 MF John Eustace 15(3) 0 0 0 2 0 17(3) 1 2 0
29 MF Michael Bryan 0(3) 0 0 0 0 0 0(3)* 0 0 0
30 MF Rob Kiernan 0 0 0 0 0 0 0 0 0 0
31 FW Marvin Sordell 1(2) 0 0 0 0(1) 1 1(3)* 1 1 0
32 MF Billy Gibson¤ 0 0 0 0 0 0 0 0 0 0
33 DF Lee Hodson 18 0 0 0 2 0 20 0 2 0
34 DF Eddie Oshodi 0(1) 0 0 0 0 0 0(1)* 0 0 0
35 GK Bo Antal 0 0 0 0 0 0 0 0 0 0
36 FW Kurtney Brooks 0 0 0 0 0(1) 0 0(1)* 0 0 0
37 GK Jonathan Bond 0 0 0 0 0 0 0 0 0 0