Modèle:Current election/doc

De Wikisisar
< Modèle:Current election
Révision datée du 21 octobre 2017 à 21:03 par TDLaouer (discussion | contributions) (1 révision importée)
(diff) ← Version précédente | Voir la version actuelle (diff) | Version suivante → (diff)
Aller à : navigation, rechercher

{{#ifeq:doc |doc

    | 

{{#ifeq:show |show

|
        }}{{#if: |
         |   {{#ifexist:Modèle:Current election
                  | [[Category:{{#switch:Modèle |Template=Template |Module=Module |User=User |#default=Wikipedia}} documentation pages]]
                  |
                 }}
        }}
    | 
   }}

This template displays the tag above and adds articles to Category:Current elections or one of its dated subcategories.

Guidelines

Check main (article) namespace links

Usage

The template takes three parameters:

  • Parameter 1 overrides the word "article"
  • Parameter 2 overrides the words "a current election"
  • Named parameter "date" categorizes into a monthly sub category for ease of maintenance. This will be added by a bot if omitted.

Examples

Code Result
subst:}}current election{{#if: ||{{{2}}}}}{{#if: ||{{{3}}}}}{{#if: ||{{{4}}}}}{{#if: ||{{{5}}}}}{{#if: ||{{{6}}}}}{{#if: ||{{{7}}}}}{{#if: ||{{{8}}}}}{{#if: ||{{{9}}}}}{{#if: ||{{{10}}}}}{{#if: ||{{{11}}}}}{{#if: ||}}}} {{#ifeq:{{{small}}}|left|}
subst:}}current election{{#if:section ||section}}{{#if:date=avril 2024 ||date=avril 2024}}{{#if: ||{{{4}}}}}{{#if: ||{{{5}}}}}{{#if: ||{{{6}}}}}{{#if: ||{{{7}}}}}{{#if: ||{{{8}}}}}{{#if: ||{{{9}}}}}{{#if: ||{{{10}}}}}{{#if: ||{{{11}}}}}{{#if: ||}}}} {{#ifeq:{{{small}}}|left|}
subst:}}current election{{#if:  || }}{{#if:a current referendum ||a current referendum}}{{#if:date=avril 2024 ||date=avril 2024}}{{#if: ||{{{5}}}}}{{#if: ||{{{6}}}}}{{#if: ||{{{7}}}}}{{#if: ||{{{8}}}}}{{#if: ||{{{9}}}}}{{#if: ||{{{10}}}}}{{#if: ||{{{11}}}}}{{#if: ||}}}} {{#ifeq:{{{small}}}|left|}

Template data

{{#if:| |This is the {{#if:|TemplateData|TemplateData}} documentation for this template used by VisualEditor and other tools.}}

See the monthly error report for this template.

TemplateData for Current election

{{#ifeq:doc|sandbox||

}} <templatedata> { "params": { "1": { "label": "Type (typically section)", "description": "Something to replace \"article\" in the template, typically \"section\"", "type": "string", "default": "article" }, "2": { "label": "Type", "description": "Allows modification of the current link instead of displaying \"a current election\"", "example": "Current Aviation Incident", "type": "string", "suggested": true }, "date": { "label": "Date", "description": "The month and year that the article is identified as current.", "example": "May 2015", "type": "date", "required": true } }, "description": "This template generates a tag to indicate that the article documents a current event." } </templatedata>

See also