Difference between revisions of "Template:MMAevent card/doc"

From blackwiki
Jump to navigation Jump to search
imported>TreyGeek
(Copying in documentation from Ravensfire's sandbox.)
 
imported>Vanisaac
m (→‎See also: clean up per WP:CAT#T and WP:AWBREQ add template:Sandbox other)
 
(6 intermediate revisions by 6 users not shown)
Line 3: Line 3:
  
 
==Usage==
 
==Usage==
This template should be used after the {{tl|MMAevent}} event header with the {{tl|User:Ravensfire/MMAevent bout}} template used for each bout and the {{tl|User:Ravensfire/MMAevent end}} event footer template used to close the table.  The template takes parameters for the name of the card and to indicate if the column headings (Weight class, Method, Round, etc) should be displayed.
+
This template should be used after the {{tl|MMAevent}} event header with the {{tl|MMAevent bout}} template used for each bout and the {{tl|MMAevent end}} event footer template used to close the table.  The template takes parameters for the name of the card and to indicate if the column headings (Weight class, Method, Round, etc.) should be displayed.
  
 
<pre>
 
<pre>
 
{{MMAevent}}
 
{{MMAevent}}
{{User:Ravensfire/MMAevent card|Main event}}
+
{{MMAevent card|Main event}}
{{User:Ravensfire/MMAevent bout
+
{{MMAevent bout
 
|Ork weight
 
|Ork weight
 
|'Ard Enuff
 
|'Ard Enuff
Line 17: Line 17:
 
|2:49
 
|2:49
 
|}}
 
|}}
{{User:Ravensfire/MMAevent end|notes=no}}
+
{{MMAevent end|notes=no}}
 
</pre>
 
</pre>
 
produces:
 
produces:
 
{{MMAevent}}
 
{{MMAevent}}
{{User:Ravensfire/MMAevent card|Main event}}
+
{{MMAevent card|Main event}}
{{User:Ravensfire/MMAevent bout
+
{{MMAevent bout
 
|Ork weight
 
|Ork weight
 
|'Ard Enuff
 
|'Ard Enuff
Line 31: Line 31:
 
|2:49
 
|2:49
 
|}}
 
|}}
{{User:Ravensfire/MMAevent end|notes=no}}
+
{{MMAevent end|notes=no}}
  
 
==Parameters==
 
==Parameters==
 
;Positional parameter 1 (no name):Card name, will put the passed text in a header row, centered
 
;Positional parameter 1 (no name):Card name, will put the passed text in a header row, centered
;Positional parameter 2 (no name):header indicator, indicates if the column name header row should be shown.  Use header=no if this is not needed such as events with multiple cards, only the first card should have the header row.  Anything else, or no parameter passed, will display the header row.
+
;Positional parameter 2, named parameter 'header':header indicator, indicates if the column name header row should be shown.  Use header=no if this is not needed such as events with multiple cards, only the first card should have the header row.  Anything else, or no parameter passed, will display the header row.
  
 
==Examples==
 
==Examples==
 
 
===Single card events===
 
===Single card events===
 
For events with a single card, you just need to include the event name as the first parameter.
 
For events with a single card, you just need to include the event name as the first parameter.
 
<pre>
 
<pre>
 
{{MMAevent}}
 
{{MMAevent}}
{{User:Ravensfire/MMAevent card|Main event}}
+
{{MMAevent card|Main event}}
{{User:Ravensfire/MMAevent bout
+
{{MMAevent bout
 
|Ork weight
 
|Ork weight
 
|'Ard Enuff
 
|'Ard Enuff
Line 53: Line 52:
 
|2:49
 
|2:49
 
|}}
 
|}}
{{User:Ravensfire/MMAevent end|notes=no}}
+
{{MMAevent end|notes=no}}
 
</pre>
 
</pre>
 
produces:
 
produces:
 
{{MMAevent}}
 
{{MMAevent}}
{{User:Ravensfire/MMAevent card|Main event}}
+
{{MMAevent card|Main event}}
{{User:Ravensfire/MMAevent bout
+
{{MMAevent bout
 
|Ork weight
 
|Ork weight
 
|'Ard Enuff
 
|'Ard Enuff
Line 67: Line 66:
 
|2:49
 
|2:49
 
|}}
 
|}}
{{User:Ravensfire/MMAevent end|notes=no}}
+
{{MMAevent end|notes=no}}
  
 
===Multiple card events===
 
===Multiple card events===
Line 73: Line 72:
 
<pre>
 
<pre>
 
{{MMAevent}}
 
{{MMAevent}}
{{User:Ravensfire/MMAevent card|Main event}}
+
{{MMAevent card|Main event}}
{{User:Ravensfire/MMAevent bout
+
{{MMAevent bout
 
|Ork weight
 
|Ork weight
 
|'Ard Enuff
 
|'Ard Enuff
Line 83: Line 82:
 
|2:49
 
|2:49
 
|}}
 
|}}
{{User:Ravensfire/MMAevent card|Preliminary (Facebook)|header=no}}
+
{{MMAevent card|Preliminary (Facebook)|header=no}}
{{User:Ravensfire/MMAevent bout
+
{{MMAevent bout
 
|Featherweight
 
|Featherweight
 
|Gregor Eisenhorn
 
|Gregor Eisenhorn
Line 93: Line 92:
 
|4:45
 
|4:45
 
|}}
 
|}}
{{User:Ravensfire/MMAevent end|notes=no}}
+
{{MMAevent end|notes=no}}
 
</pre>
 
</pre>
 
produces:
 
produces:
 
{{MMAevent}}
 
{{MMAevent}}
{{User:Ravensfire/MMAevent card|Main event}}
+
{{MMAevent card|Main event}}
{{User:Ravensfire/MMAevent bout
+
{{MMAevent bout
 
|Ork weight
 
|Ork weight
 
|'Ard Enuff
 
|'Ard Enuff
Line 107: Line 106:
 
|2:49
 
|2:49
 
|}}
 
|}}
{{User:Ravensfire/MMAevent card|Preliminary (Facebook)|header=no}}
+
{{MMAevent card|Preliminary (Facebook)|header=no}}
{{User:Ravensfire/MMAevent bout
+
{{MMAevent bout
 
|Featherweight
 
|Featherweight
 
|Gregor Eisenhorn
 
|Gregor Eisenhorn
Line 117: Line 116:
 
|4:45
 
|4:45
 
|}}
 
|}}
{{User:Ravensfire/MMAevent end|notes=no}}
+
{{MMAevent end|notes=no}}
  
 
==Parameters==
 
==Parameters==
Line 126: Line 125:
 
[[:Category:Martial arts templates]]
 
[[:Category:Martial arts templates]]
  
== See also ==
+
==See also==
 
+
<includeonly>{{Sandbox other||
<includeonly>
 
 
<!-- Categories and interwikis go here: -->
 
<!-- Categories and interwikis go here: -->
 
+
[[Category:Mixed martial arts templates]]
</includeonly>
+
}}</includeonly>

Latest revision as of 01:29, 26 April 2020

This template is part of a series of MMA event templates to make it easier to record the results of a MMA event. This particular template is used to create the header row for each card. Multiple cards can exist for a single event so this template can be used multiple times.

Usage

This template should be used after the {{MMAevent}} event header with the {{MMAevent bout}} template used for each bout and the {{MMAevent end}} event footer template used to close the table. The template takes parameters for the name of the card and to indicate if the column headings (Weight class, Method, Round, etc.) should be displayed.

{{MMAevent}}
{{MMAevent card|Main event}}
{{MMAevent bout
|Ork weight
|'Ard Enuff
|defeated
|Go Fasta Red
|KO (Ork elbow)
|2
|2:49
|}}
{{MMAevent end|notes=no}}

produces:

Main event
Weight class Method Round Time Notes
Ork weight 'Ard Enuff defeated Go Fasta Red KO (Ork elbow) 2 2:49

Parameters

Positional parameter 1 (no name)
Card name, will put the passed text in a header row, centered
Positional parameter 2, named parameter 'header'
header indicator, indicates if the column name header row should be shown. Use header=no if this is not needed such as events with multiple cards, only the first card should have the header row. Anything else, or no parameter passed, will display the header row.

Examples

Single card events

For events with a single card, you just need to include the event name as the first parameter.

{{MMAevent}}
{{MMAevent card|Main event}}
{{MMAevent bout
|Ork weight
|'Ard Enuff
|def.
|Go Fasta Red
|KO (Ork elbow)
|2
|2:49
|}}
{{MMAevent end|notes=no}}

produces:

Main event
Weight class Method Round Time Notes
Ork weight 'Ard Enuff def. Go Fasta Red KO (Ork elbow) 2 2:49

Multiple card events

For multiple cards, the column headings should displayed only with the first card so you will need to pass two parameters. The main card should always be listed first.

{{MMAevent}}
{{MMAevent card|Main event}}
{{MMAevent bout
|Ork weight
|'Ard Enuff
|def.
|Go Fasta Red
|KO (Ork elbow)
|2
|2:49
|}}
{{MMAevent card|Preliminary (Facebook)|header=no}}
{{MMAevent bout
|Featherweight
|Gregor Eisenhorn
|def.
|Gideon Ravenor
|TKO (punch)
|3
|4:45
|}}
{{MMAevent end|notes=no}}

produces:

Main event
Weight class Method Round Time Notes
Ork weight 'Ard Enuff def. Go Fasta Red KO (Ork elbow) 2 2:49
Preliminary (Facebook)
Featherweight Gregor Eisenhorn def. Gideon Ravenor TKO (punch) 3 4:45

Parameters

The template has two optional parameters:

Positional parameter 1 (no name)
The name of the card. If nothing is passed, the card name will be blank
header
Indicates if the header row should be added immediately below the card name row. If "no" is passed, the header row is not displayed; otherwise the row is displayed below the card name.

Category:Martial arts templates

See also