Episodes list/doc

This template creates a table row, for use in a list of episodes, primarily for television. The number, and use, of columns a table has, is defined by the beginning wikitext of that table (further explained below), and is not defined by this template. In order for this template to provide a table row for a given article, parameters must either be included, or excluded. An included parameter, although empty, will provide a cell for that field (and thus column), while excluding a parameter will not provide a cell for that field.

## Parameters

This is where information from the template is placed when rendered (*`{{{LineColor}}}`, `{{{TopColor}}}`, and `{{{RowColor}}}` are not shown, since there's no text to display*):

## Using the template

When using optional parameters (such as `Aux1` or `AltDate`) only list the parameters that are being used, and adjust the table headers accordingly. This will help avoid confusion when one entry has a parameter filled out, and another does not. A table cell will be open for each listed parameter, whether it is filled out or not.

To apply an entry to an episode listing, add this template where the episode would go in the **List of episodes**. The full syntax is as follows, remove the parameters that are not being used in the table:

```
{{Episode list
}}

```

Because this is only part of a WikiTable, you first must "open" the WikiTable. You need to edit this example according to the optional parameters that you want to show in your table, ensuring that the code used complies with MOS:ACCESS requirements. An explanation of how to do this is detailed at WP:DTT. For example, to create a list with only `EpisodeNumber`, `Title`, `OriginalAirDate`, `ProdCode`, and `ShortSummary` parameters, open the table as follows:

```
{|class="wikitable plainrowheaders" style="width:100%; margin:auto;"
! scope="col" style="width:3em;" | No.
! scope="col" | Title
! scope="col" style="width:12em;" | Original air date
! scope="col" | Production code

```

The {{[[Template:Episode list|Episode list]]}} templates would then follow here:

```
{{Episode list
}}
{{Episode list
}}

```

After the final episode entry (template) you will close the WikiTable with:

```

```

### Examples

The above code would appear as follows:

**Lua error in Module:Episode\_list at line 1: '=' expected near 'p'.**

A more complex case would look like the following:

```
{|class="wikitable plainrowheaders" style="width:100%; margin:auto; table-layout:fixed;"
! scope="col" style="background-color: #812f09; color: #ffffff;" | Number<br />in series
! scope="col" style="background-color: #812f09; color: #ffffff;" | Number<br />in season
! scope="col" style="background-color: #812f09; color: #ffffff;" | Title
! scope="col" style="background-color: #812f09; color: #ffffff;" | Directed by
! scope="col" style="background-color: #812f09; color: #ffffff;" | Written by
! scope="col" style="background-color: #812f09; color: #ffffff;" | Ben's location
! scope="col" style="background-color: #812f09; color: #ffffff; width:12em;" | Original air date
! scope="col" style="background-color: #812f09; color: #ffffff;" | Production code
! scope="col" style="background-color: #812f09; color: #ffffff;" | U.S. viewers<br />(million)
{{Episode list
}}
{{Episode list
}}

```

**Lua error in Module:Episode\_list at line 1: '=' expected near 'p'.**

## Sublists

Occasionally, when dealing with a very long series, you may wish to break the list up into separate sublists. When doing so, the list should be broken at season breaks, or otherwise years.

Sublists should be named as "List of *X* episodes (season *y*)", and transcluded onto the main list to prevent ending up with two lists of duplicate information. For sublist pages, you should use Template:Tld for each episode, where "List of *X* episodes" is the name of the main episode list. So, for instance, if you're working on List of Bleach episodes, you would split it into List of Bleach episodes (season 1) and List of Bleach episodes (season 2), and each episode on the sublist would use Template:Tld.

When transcluded onto the main list, this template removes any summaries, and alternates the background row color between light and dark gray, depending on the value of `{{{EpisodeNumber}}}`. Occasionally, a multi-part episode will skew the pattern between odd and even `EpisodeNumber`s, to rectify this, use the `RowColor` parameter. A "`On`" input will color the row dark gray, like an even number normally would, on the "List of *X* episodes" page, while a "`Off`" input will color the row light gray, like an odd number normally would.

For the purpose of transclusion, each sublist must make use of `<onlyinclude>` tags, with the opening tag just before the WikiTable, and the closing tag at the very end of the table. This prevents the lead, external links, templates, categories, interwiki links, and all other unnecessary information from being transcluded onto the main list.

When transcluding onto the main list, you should make use of {{[[Template:main|main]]}}. For example, referring to *Bleach* again, the main list would have the following code under the "Episode list" header:

```
== Season 1 ==
{{main|List of Bleach episodes (season 1)}}
{{:List of Bleach episodes (season 1)}}
<!-- To edit the episodes in this section, you need to edit the article listed above. -->

== Season 2 ==
{{main|List of Bleach episodes (season 2)}}
{{:List of Bleach episodes (season 2)}}
<!-- To edit the episodes in this section, you need to edit the article listed above. -->

```

Note the colon (**:**) at the beginning of the transclusions (for example, `{{:List of` ...); this is necessary when transcluding an article. If you tried to transclude List of Bleach episodes (season 1), without using the colon, you would get Template:List of Bleach episodes (season 1), a redlink to a nonexistent template.

### Examples

If the following code is on List of *Lost* episodes (season 3):

```
<onlyinclude>
{| class="wikitable plainrowheaders" style="width:100%; margin:auto;"
! scope="col" style="background-color: #282;" |No. in<br />series
! scope="col" style="background-color: #282;" |No. in<br />season
! scope="col" style="background-color: #282;" |Title
! scope="col" style="background-color: #282;" |Directed by
! scope="col" style="background-color: #282;" |Written by
! scope="col" style="background-color: #282;" |Featured<br />character(s)
! scope="col" style="background-color: #282;" |Original air date
! scope="col" style="background-color: #282;" |U.S. viewers<br />(million)
{{Episode list/sublist|List of Lost episodes
}}
{{Episode list/sublist|List of Lost episodes
}}
{{Episode list/sublist|List of Lost episodes
}}
</onlyinclude>

```

If the following code is on List of *Lost* episodes (season 4):

```
<onlyinclude>
{| class="wikitable plainrowheaders" style="width:100%; margin:auto;"
! scope="col" style="background-color: #36F;" |No. in<br />series
! scope="col" style="background-color: #36F;" |No. in<br />season
! scope="col" style="background-color: #36F;" |Title
! scope="col" style="background-color: #36F;" |Directed by
! scope="col" style="background-color: #36F;" |Written by
! scope="col" style="background-color: #36F;" |Featured<br />character(s)
! scope="col" style="background-color: #36F;" |Original air date
! scope="col" style="background-color: #36F;" |U.S. viewers<br />(million)
{{Episode list/sublist|List of Lost episodes
}}
{{Episode list/sublist|List of Lost episodes
}}
{{Episode list/sublist|List of Lost episodes
}}
</onlyinclude>

```

And if the following code is on List of *Lost* episodes:

```
== Season 3 ==
{{main|List of Lost episodes (season 3)}}
{{:List of Lost episodes (season 3)}}
<!-- To edit the episodes in this section, you need to edit the article listed above. -->

== Season 4 ==
{{main|List of Lost episodes (season 4)}}
{{:List of Lost episodes (season 4)}}
<!-- To edit the episodes in this section, you need to edit the article listed above. -->

```

List of *Lost* episodes will appear as follows:

Season 3
Template:Main

**Lua error in Module:Episode\_list at line 1: '=' expected near 'p'.**
**Lua error in Module:Episode\_list at line 1: '=' expected near 'p'.**

Season 4
Template:Main

**Lua error in Module:Episode\_list at line 1: '=' expected near 'p'.**
**Lua error in Module:Episode\_list at line 1: '=' expected near 'p'.**

## Tips

It may be helpful to include a hidden message that will appear when someone edits the article. Placed above the table headers and under the article section, such as:

```
==Episodes==
<!-- For help with this template see http://en.wikipedia.org/wiki/Template:Episode_list -->
<onlyinclude>
{| class="wikitable plainrowheaders"

```

This message won't be visible when normally viewing the article. A message such as this notes where one can get help for the template.

## Microformat

Template:UF-hcal-multi
For shows where each episode is from a different, single, specific place (for example, Time Team, one of the *Aux* fields can contain the coordinates, applied using {{[[Template:coord|coord]]}}.

Cite error: `<ref>` tags exist for a group named "N", but no corresponding `<references group="N"/>` tag was found