From TheKolWiki
Jump to: navigation, search


#ifexpr: {{CURRENTYEAR}} - {{{year}}} <= 0 | style="background-color: #AAFFAA; {{{style|}}}" | {{ #ifexpr: {{CURRENTYEAR}} - {{{year}}} = 1 | style="background-color: #CCFF99; {{{style|}}}" | {{ #ifexpr: {{CURRENTYEAR}} - {{{year}}} = 2 | style="background-color: #FFFF77; {{{style|}}}" | style="background-color: #FFCCCC; {{{style|}}}" }} }}


This is a template for applying common CSS styles to any content subject to standard restrictions. The template picks the appropriate style based on the current year ({{CURRENTYEAR}}), so that all tables using this template will be automatically updated when the year changes.

This template renders as a style="...". It can be used to control the style of a table row or cell, or to directly style text using a <span> tag.

Due to how the wiki software (and HTML) works, you cannot use a style="" statement along with this template to specify additional styles. Instead, you must pass additional CSS styles using the style parameter.

When you use this template in any document, please also insert {{Template:StandardRestrictedStyle/Legend}}:

Limited-time content
2019 or older content No longer available in in-season challenge paths.
2020 content Will not be available in in-season challenge paths in 2023 or later.
2021 content Will not be available in in-season challenge paths in 2024 or later.
2022 content Will not be available in in-season challenge paths in 2025 or later.


All arguments are keyword only.

  • year: Required. The year in which the current item, skill, or familiar was released. This is used to pick the correct style.
  • style: Optional. Additional CSS style(s) to apply.


{| class="wikitable" style="text-align: center"
! Item
! Released on
| [[packaged knock-off retro superhero cape]]
| {{Template:StandardRestrictedStyle|year=2020}} | Nov. 2020<br>(styling a cell)
| [[unopened diabolic pizza cube box]]
| {{Template:StandardRestrictedStyle|year=2019|style=text-align: right; font-weight: bold}} | Nov. 2019<br>(applying additional styles)
|- {{Template:StandardRestrictedStyle|year=2018}}
| [[voter registration form]]
| Nov. 2018<br>(styling entire rows)
| [[pantogram]]
| {{Template:StandardRestrictedStyle|year=2017}} | Nov. 2017
| [[Build-a-City Gingerbread kit]]
| {{Template:StandardRestrictedStyle|year=2016}} | Dec. 2016

The above is rendered as:

Item Released on
packaged knock-off retro superhero cape Nov. 2020
(styling a cell)
unopened diabolic pizza cube box Nov. 2019
(applying additional styles)
voter registration form Nov. 2018
(styling entire rows)
pantogram Nov. 2017
Build-a-City Gingerbread kit Dec. 2016
Some text that describes <span {{Template:StandardRestrictedStyle|year=2017}}>content released in 2017</span> as well as <span {{Template:StandardRestrictedStyle|year=2020}}>content released in 2020</span>.

The above is rendered as:

Some text that describes content released in 2017 as well as content released in 2020.