Template:Episode table
| Template documentation follows |
|---|
| Note: the template above may sometimes be partially or fully invisible. |
| Visit "Template:Episode table/doc" to edit its documentation if it is available. (How does this work?) |
| This template is used on approximately 29,000 pages and changes may be widely noticed. Test changes in the template's /sandbox or /testcases subpages, or in your own user subpage. Consider discussing changes on the talk page before implementing them. |
| This template uses Lua: |
| This template is used by one or more bots. If you intend to change this template in any significant way, move it, or nominate it for deletion, please inform the bot operators. Thank you. The relevant bots are: User:cewbot/log/20201008/configuration |
{{Episode table}} easily adds a standard header row to episode tables for television series, with up to 13 different columns, and optionally set the widths of these columns, and includes the {{Episode list}} template in the "episode" parameter. Cells are included by declaring the specific variable in one of two ways: |title= includes the "Title" cell with no set width, and |title=30 includes the "Title" cell with a width of 30%.
For pages using a manually created table, either convert them to use this template, or tag them with {{Convert to Episode table}}, which will place the pages in Category:Articles lacking Episode table templates (0).
Usage
Parameters
|
|---|
{{Episode table
|caption = TEXT
|background = COLOR
|total_width = WIDTH
|overall = WIDTH
|overall2 = WIDTH
|series = WIDTH
|season = WIDTH
|title = WIDTH
|aux1 = WIDTH
|director = WIDTH
|writer = WIDTH
|aux2 = WIDTH
|aux3 = WIDTH
|airdate = WIDTH
|altdate = WIDTH
|prodcode = WIDTH
|viewers = WIDTH
|aux4 = WIDTH
|country = COUNTRY
|viewers_type = TEXT
|overallT = TEXT
|seriesT = TEXT
|seasonT = TEXT
|titleT = TEXT
|aux1T = TEXT
|directorT = TEXT
|writerT = TEXT
|aux2T = TEXT
|aux3T = TEXT
|airdateT = TEXT
|altdateT = TEXT
|prodcodeT = TEXT
|viewersT = TEXT
|aux4T = TEXT
|overallR = REFERENCE
|seriesR = REFERENCE
|seasonR = REFERENCE
|titleR = REFERENCE
|aux1R = REFERENCE
|directorR = REFERENCE
|writerR = REFERENCE
|aux2R = REFERENCE
|aux3R = REFERENCE
|airdateR = REFERENCE
|altdateR = REFERENCE
|prodcodeR = REFERENCE
|viewersR = REFERENCE
|aux4R = REFERENCE
|episodes = EPISODE LISTS/PART ROWS
|dontclose = BOOLEAN
}}
|
Examples
Standard columns
{{Episode table |caption=This is a caption |background=#B40000 |overall=5 |season=5 |title=17 |director=11 |writer=37 |airdate=10 |prodcode=6 |viewers=9 |country=U.S.}}
| No. overall | No. in season | Title | Directed by | Written by | Original release date | Prod. code | U.S. viewers (millions) |
|---|
All columns
{{Episode table |overall= |season= |title= |aux1= |director= |writer= |aux2= |aux3= |airdate= |altdate= |prodcode= |viewers= |aux4= |country= |aux1T=Aux1 |aux2T=Aux2 |aux3T=Aux3 |aux4T=Aux4 |altdateT=AltDate}}
| No. overall | No. in season | Title | Aux1 | Directed by | Written by | Aux2 | Aux3 | Original release date | AltDate | Prod. code | Viewers (millions) | Aux4 |
|---|
With Episode list template
Code
|
|---|
{{Episode table |background = #005F6C |overall = 6 |series = 6 |title = 20 |director = 14 |writer = 15 |airdate = 16 |prodcode = 8 |viewers = 9 |aux4 = 6 |country = UK |overallT = Story |seriesT = Episode |aux4T = AI |aux4R = {{Dummy reference}} |dontclose = y}}
{{Episode list
|EpisodeNumber = 203
|EpisodeNumber2 = 1
|Title = [[The Eleventh Hour (Doctor Who)|The Eleventh Hour]]
|DirectedBy = Adam Smith
|WrittenBy = [[Steven Moffat]]
|OriginalAirDate = {{Start date|2010|4|3|df=y}}
|ProdCode = 1.1
|Viewers = 10.09
|Aux4 = 86
|LineColor = 005F6C
}}
{{Episode list
|EpisodeNumber = 204
|EpisodeNumber2 = 2
|Title = [[The Beast Below]]
|DirectedBy = [[Andrew Gunn (director)|Andrew Gunn]]
|WrittenBy = Steven Moffat
|OriginalAirDate = {{Start date|2010|4|10|df=y}}
|ProdCode = 1.2
|Viewers = 8.42
|Aux4 = 86
|LineColor = 005F6C
}}
{{End|html=y|Episode table}}
|
| Story | Episode | Title | Directed by | Written by | Original release date | Prod. code | UK viewers (millions) | AI [1] |
|---|---|---|---|---|---|---|---|---|
| 203 | 1 | "The Eleventh Hour" | Adam Smith | Steven Moffat | 3 April 2010 | 1.1 | 10.09 | 86 |
| 204 | 2 | "The Beast Below" | Andrew Gunn | Steven Moffat | 10 April 2010 | 1.2 | 8.42 | 86 |
Episode with multiple titles
Code
|
|---|
{{Episode table |background=#69D0E3 |overall= |title= |titleT=English title |alttitleT=Japanese title |alttitleR=<ref /> |airdate= |episodes=
{{Episode list/sublist|Ninja Nonsense
| NumParts = 2
| EpisodeNumber = 1
| Title_1 = Shinobu, the Ninja Apprentice, Appears
| TranslitTitle_1 = Minarai Ninja, Shinobu Kenzan no Maki
| NativeTitle_1 = 見習い忍者、忍見参の巻
| Title_2 = The Master Appears
| TranslitTitle_2 = Tōryō, Arawaru no Maki
| NativeTitle_2 = 頭領、現るの巻
| NativeTitleLangCode = ja
| OriginalAirDate = {{Start date|2004|7|8}}
| LineColor = #69D0E3
}}
}}
|
| No. | English title Japanese title [10] | Original release date |
|---|---|---|
| 1 | "Shinobu, the Ninja Apprentice, Appears" Transliteration: "Minarai Ninja, Shinobu Kenzan no Maki" (Japanese: 見習い忍者、忍見参の巻) | July 8, 2004 |
| "The Master Appears" Transliteration: "Tōryō, Arawaru no Maki" (Japanese: 頭領、現るの巻) | ||
Parted seasons
For seasons which have been split into parts, use {{Media table section}}, as per the examples below:
{{Media table section |c=#183E54 |part=1}}
| No. overall | No. in season | Title | Directed by | Written by | Original release date | U.S. viewers (millions) | ||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Part 1 | ||||||||||||
{{Media table section |c=#061453 |subtitle=''Athelstan's Journal''}}
| No. | Title | Directed by | Written by | Original release date | Length (minutes) | |||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Athelstan's Journal | ||||||||||||
Parameters
Each cell parameter has an alias to match the parameters used in {{Episode list}}. In the Cell Inclusion & Widths rows, the original parameter is listed, followed by its episode-list alias. This means that this:
{{Episode table |background=#B40000 |overall=5 |season=5 |title=17 |director=11 |writer=37 |airdate=10 |prodcode=6 |viewers=9 |country=U.S.}}
will produce exactly the same as this:
{{Episode table |background=#B40000 |EpisodeNumber=5 |EpisodeNumber2=5 |Title=17 |DirectedBy=11 |WrittenBy=37 |OriginalAirDate=10 |ProdCode=6 |Viewers=9 |country=U.S.}}
| Parameter | Description | Type | Status | ||
|---|---|---|---|---|---|
| Table caption | caption | A caption should be provided that describes in general the content of the table. By default, the caption uses {{Screen reader-only}} to not be visually displayed in a browser, but still be present and voiced by a screen reader for accessibility. To make the caption visible, use |show_caption=y. e.g. NCIS season 11 episodes
|
Wikitext | Required for accessibility | |
| Background color | background | The background color of the header row. If no color is specified, the background defaults to #CCCCFF. Format: #595959 |
String | Optional | |
| Total width | total_width | Table width defaults to 100%. For tables that are less than 100%, set this field as necessary, with or without a percentage sign. Set to "auto" or blank to remove the set width and allow the table to display naturally. Format: 75 |
Number | Optional | |
| Anchor | anchor | In {{Episode list}}, |EpisodeNumber= is a number representing the episode's order in the series. For example, the first episode would be 1. When defined, the specified number also generates a link anchor, prefixed by ep; for example, [[List of episodes#ep1]]; see more at Template:Episode list § EpisodeNumber. In the case of multiple tables with the same anchored episode number, the anchor can be made unique with the |anchor= parameter in the call of {{Episode table}}. For example, if |anchor= in this template is set to |anchor=Minisodes, then the anchor will be [[List of episodes#Minisodesep1]]. Note that the |anchor= parameter has no effect if the |episodes= parameter is absent.
|
Wikitext | Optional | |
| Cell Inclusion & Widths[lower-alpha 1] | Overall Number | overall EpisodeNumber |
The inclusion (and optionally the width) of the "No." / "No. overall" cell. Use |forceoverall=y to force this column to display "No. overall" when season/series is not set. Change the "overall" term by using |overall_type=)Format: 10 / <blank> |
Number | Optional |
| Season | season EpisodeNumber2 |
The inclusion (and optionally the width) of the "No. in season" cell. (Inclusion will set "No." cell to "No. overall" if overallT is unset. Change the "season" term by using |season_type=)Format: 10 / <blank> Note: "series" and "season" cannot be included in the same table. |
Number | Optional | |
| Series | series EpisodeNumber2Series |
The inclusion (and optionally the width) of the "No. in series" cell. (Inclusion will set "No." cell to "No. overall" if overallT is unset. Change the "series" term by using |series_type=)Format: 10 / <blank> Note: "series" and "season" cannot be included in the same table. |
Number | Optional | |
| Title | title Title |
The inclusion (and optionally the width) of the "Title" cell. An alternate title below the "Title" header can also be included by using |alttitleT=, which can also be used with |alttitleR= to include the alternate reference; inclusion of these does not create a new column, but only modifies the "Title" cell, |alttitle= is not a valid parameter).Format: 10 / <blank> |
Number | Optional | |
| Aux1 | aux1 Aux1 |
The inclusion (and optionally the width) of the "Aux1" cell. Format: 10 / <blank> |
Number | Optional | |
| Director | director DirectedBy |
The inclusion (and optionally the width) of the "Directed by" cell. Format: 10 / <blank> |
Number | Optional | |
| Writer | writer WrittenBy |
The inclusion (and optionally the width) of the "Written by" cell. Format: 10 / <blank> |
Number | Optional | |
| Aux2 | aux2 Aux2 |
The inclusion (and optionally the width) of the "Aux2" cell. Format: 10 / <blank> |
Number | Optional | |
| Aux3 | aux3 Aux3 |
The inclusion (and optionally the width) of the "Aux3" cell. Format: 10 / <blank> |
Number | Optional | |
| Air/Release Date | airdate OriginalAirDate |
The inclusion (and optionally the width) of the "Original release date" cell. Format: 10 / <blank> |
Number | Optional | |
| Alternative Air/Release Date | altdate AltDate |
The inclusion (and optionally the width) of the "Alternative Release Date" cell. Format: 10 / <blank> |
Number | Optional | |
| Production Code | prodcode ProdCode |
The inclusion (and optionally the width) of the "Production code" cell. Format: 10 / <blank> |
Number | Optional | |
| Viewers | viewers Viewers |
The inclusion (and optionally the width) of the "Viewers" cell. Format: 10 / <blank> |
Number | Optional | |
| Aux4 | aux4 Aux4 |
The inclusion (and optionally the width) of the "Aux4" cell. Format: 10 / <blank> |
Number | Optional | |
| Content | Country | country | The series' originating country; displayed before "viewers". (Exclusion capitalized "Viewers"; inclusion un-capitalizes "viewers".) Format: U.S. |
String | Optional / Unrequired when viewers is not set |
| Viewers type | viewers_type | The numeric format that viewers are grouped within the episode table. Set to "millions" by default. Including the parameter but leaving it blank will disclude the bracketed format. Format: thousands |
String | Optional | |
| Variable Content | {variable}T | Custom content of any cell (e.g. overallT, titleT). Format: Any string |
String | Optional / Required when aux{1-4} and altdate set | |
| Reference | {variable}R | Reference for any cell (e.g. overallR, titleR). If Wikipedia's link colours are not WCAG 2 AAA Compliant with the background colour, {{Episode table/ref}} is used to provide the reference with a compliant background colour. Format: Reference |
Reference | Optional | |
| Episodes | episodes | An infinite number of consecutive episode rows. Format: {{Episode list}} or {{Media table section}} |
Template | Required when using {{Episode list}} | |
| Don't Close | dontclose | Set this parameter to "y" to be able to close the initial wikicode declaration of the episode table, but to be able to continue displaying the separate episode rows after the header but outside of the initial declaration. Particularly useful for when the individual rows have to be transcluded outside of the article and thus must be outside of a template, or in articles with lots of templates that would otherwise exceed the post-expand include size limit. To close the initial declaration, {{End|html=y|Episode table}} must be used.
|
Text | Optional | |
TemplateData
TemplateData documentation used by VisualEditor and other tools
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
See a monthly parameter usage report for Template:Episode table in articles based on its TemplateData.
TemplateData for Episode table No description.
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Tracking categories
- Category:Articles using Template:Episode table with a visible caption (0)
- Category:Articles using Template:Episode table with invalid colour combination (0)
- Category:Articles using Template:Episode table with no column parameters (0)
- Category:Pages using episode table with unknown parameters (0)
See also
{{Media table section}}{{Episode table/ref}}
Film- and television-related infobox templates | |
|---|---|
| Film | |
| Television | |
| Misc video | |
| Industry | |
| Technical | |
| Fiction | |
| Template modules | |
| Related |
- Template:Episode table invokes Module:Navbox using Lua.
Usage
This template can be used to make a standard navigation box. It is intended for use within another template that standardises the title and contents of the box (see Template:ShipNavbox). This template SHOULD NOT be used directly within articles, as it creates a maintenance burden to do so whenever the contents of the box have to be updated.
The purpose of this template is to standardise the attributes of all navigation boxes, for example, their colours and other CSS attributes. The template is fairly simple, and could be extended to add other features in the future. Using this template allows changes to be implemented much quicker and easier than editing each template separately.
Syntax
{{navbox
|state = uncollapsed, collapsed, plain, autocollapse (default)
|name = mandatory - name of the template
|style = optional - style for the whole table
|title = mandatory - navbox header
|gtitleN = optional - title of N-th group of items
|styleN = optional - style for groupN; i.e. text-align
|groupN = mandatory - list of groups of items
|fstyle = optional - style for footer ; i.e. text-align
|footer = optional - navbox footer
}}
- Groups: Currently there is no technical limit to the maximum number of groups.
- Groups of items can be added as parameters: group1, group2, group3, ... up to groupN.
- Group title: Each group has its own title parameter: gtitle1, gtitle2, gtitle3, ... up to gtitleN. Note that the default width for the first column is 15%.
- Group style: Style may also be customised to each group in: style1, style2, style3, ... up to styleN.
- Note that neither the title nor the items have any wiki-links built into the template. As a result, users of the template are free to use wiki-links as they wish.
- Line breaks: Line-breaks (
<br />) are unnecessary, as text wrapping is done automatically by the template. This also includes links and text in gtitleN and groupN. - Bullets: Create unordered lists with lines beginning with *.
- Pipe links: Because of the nature of template syntax, it may be necessary to use Template:! (
{{!}}).
States
- Autocollapse: By default, the state of a navbox is "autocollapsed". This means that if the number of navboxes in a page exceeds the maximum allocation of the collapsible navboxes, then the remaining navboxes are collapsed automatically. For more information (or to change the setting), see MediaWiki:Common.js.
- Currently, the autocollapse allocation is 2 (see MediaWiki:Common.js). This means that if there are 3 navboxes in a page, the third and subsequent navboxes will be collapsed automatically.
- Uncollapsed: Forces the navbox to be displayed.
- All of the navboxes in this documentation are in the uncollapsed state.
- Collapsed: The reverse of uncollapsed. Forces the navbox to be hidden instead.
- Navboxes with a height of more than 300 pixels will also be collapsed automatically. For more information (or to change the setting), see MediaWiki:Common.js.
- Plain: Removes the "show/hide" link.
Sub-groups
- For larger navboxes, it may be necessary to include sub-groups within a particular group of items. It is also possible to collapsible navboxes within the parent navbox, see Collapsible sub-groups.
- To create sub-groups within
{{navbox}}, certain parameters are to be included:- The parent navbox group (i.e. group2 in the example below) requires the type parameter (gtype2 = Subgroup).
- The nested navbox (sub-group) requires the inclusion of the sub-group parameter (subgroup = yes). This enables the template to differentiate between the sub-group and the parent navbox.
{{navbox
|name =
|title =
|gtitle1 =
|group1 =
|gtitle2 =
|gtype2 = Subgroup (mandatory)
|group2 =
{{navbox
|subgroup = yes (mandatory)
|gtitle1 =
|group1 =
|gtitle2 =
|group2 =
}}
}}
Collapsible sub-groups
- For extremely long navboxes, it is recommended to use collapsible navboxes within the parent navbox. Further sub-groups can then be added to these collapsible navboxes.
- To create collapsible sub-groups within
{{navbox}}, these parameters need to be included:- The parent navbox is almost always uncollapsed (state=uncollapsed).
- The parent navbox group (i.e. group1 in the example below) requires the type parameter (gtype1 = Subgroup).
- The nested collapsible navbox requires the inclusion of the collapsible parameter (collapsible = yes). This enables the template to differentiate between the collapsible navbox and the parent navbox.
- The nested collapsible navbox is forcefully collapsed (state=collapsed).
{{navbox
|state = uncollapsed
|name =
|gtype1 = Subgroup
|group1 =
{{navbox
|collapsible = yes
|state = collapsed
|title =
|gtitle1 =
|group1 =
|gtitle2 =
|group2 =
}}
}}
Use of images
- The use of images in navboxes is permitted, but please resize the images to keep them small. Inventory-sized images (25-30 pixels) are recommended.
- Please use {{t|plink}} to create links with images. Use {{t|plink}} for any case where text is not desired after the link. It functions the same as {{t|plink}}, but it does not produce a wikilink in text. Use {{t|chatl}} to link chatheads. These templates create links for both the image and text (except for {{t|plink}}) using far less wikicode than the standard syntax.
Link and file share the same name
{{plink|Item}}
File name differs from the link
{{plink|Item|File}}
Link and file share the same name, but different text is desired to display
{{plink|Item|alt=Text}}
File name differs from the link and different text is desired to display
{{plink|Item|File|alt=Text}}
Categorising
Navboxes are very useful for transcluding categories onto a large number of pages that share both a trait and the navigation box. For example: Template:ShipNavbox transcludes Category:Ships onto every page that uses it.
There are 2 methods of categorising pages with navboxes:
The first way is with {{t|Ctg}}. This is the preferred method, and can be used in most cases. The rules and operations for the Category handler template are very simple; however, they are enough to produce the desired results on most pages.
Categorisation should only be used on a template for large-scale addition. It is unhelpful, for example, to use a rule that only applies to 1 page.
Examples
To see the following navboxes in action, see Template:Navbox.
Single line navbox with centered list
{{navbox
|name =
|title =
|style1 = text-align:center
|group1 =
}}
Navbox with standard footer
{{navbox
|name =
|title =
|gtitle1 =
|group1 =
|footer = Centered footer
}}
Navbox with styled footer
{{navbox
|name =
|title =
|gtitle1 =
|group1 =
|fstyle = text-align:right
|footer = Right-aligned footer
}}
Multiple line navbox
{{navbox
|name =
|title =
|gtitle1 = Group title 1
|group1 =
|gtitle2 = Group title 2
|group2 =
|gtitle3 = Group title 3
|group3 =
}}
Collapsed navbox
{{navbox
|state = collapsed
|name =
|title =
|style1 = text-align:center
|group1 =
}}
Plain navbox with Tnavbar
{{navbox
|state = plain
|name =
|title =
|style1 = text-align:center
|group1 =
}}
Plain navbox without Tnavbar
{{navbox
|state = plain
|title =
|style1 = text-align:center
|group1 =
}}
Complicated navbox
{{navbox
|state = uncollapsed
|name =
|title =
|gtitle1 = Level 1 Title 1
|group1 =
|gtitle2 = Level 1 Title 2
|group2 =
|gtitle3 = Level 1 Title 3
|group3 =
|gtitle4 = Level 1 Title 4
|group4 =
|gtitle5 = Level 1 Title 5
|gtype5 = Subgroup
|group5 =
{{navbox
|subgroup = Yes
|gtitle1 = Level 2 Title 1
|group1 =
|gtitle2 = Level 2 Title 2
|group2 =
|gtitle3 = Level 2 Title 3
|gtype3 = Subgroup
|group3 =
{{navbox
|subgroup = Yes
|gtitle1 = Level 3 Title 1
|group1 =
|gtitle2 = Level 3 Title 2
|group2 =
}}
|gtitle4 = Level 2 Title 4
|group4 =
}}
|gtitle6 = Level 1 Title 6
|group6 =
|gtitle7 = Level 1 Title 7
|group7 =
|fstyle =
|footer =
}}
Preventing unwanted documentation
The Navbox template's documentation is automatically transcluded under the navbox on any Template namespace page. It is not transcluded when used as a sub-group or collapsible sub-group template (subgroup= yes or collapsible=yes).
Should the documentation appear when it is unwanted, it can be hidden by setting the doc parameter doc=no on the template. In most cases, the doc parameter is NOT used and the parameter is removed completely.
Cite error: <ref> tags exist for a group named "lower-alpha", but no corresponding <references group="lower-alpha"/> tag was found