Template:StateForum/doc View history

(Created initial doc)
 
(fixed issue)
 
(5 intermediate revisions by the same user not shown)
Line 4: Line 4:


== Usage ==
== Usage ==
Place {{tl|StateForum}} on a page where either a URL to a state or region forum is desired. Alternately the template can also determine the name of the region based on the state name passed to it.
Place {{tl|StateForum}} on a page where either a URL to a state or region forum is desired. Alternately the template can also determine the name of the region based on the state name or the states in a region. It uses the data in {{tl|StateForum/List}}.


{{Pre2|<nowiki>
{{Pre2|<nowiki>
{{StateForum
{{StateForum
| STATENAME or  
| STATENAME or  
   STATE ABBREVIATION
   STATE ABBREVIATION or
  REGION NAME
| state-id or  
| state-id or  
   region-id or  
   region-id or  
   region-name
   region-name or
  regional-coordinator or
  state-list or
  state-list-long
}}</nowiki>
}}</nowiki>
}}
}}
Line 20: Line 24:
::'''STATENAME''' - The full name of the state or territory (Alaska, California, Texas, etc.)
::'''STATENAME''' - The full name of the state or territory (Alaska, California, Texas, etc.)
::'''STATE ABBREVIATION''' - The two letter state abbreviation (AK, CA, TX, etc.)
::'''STATE ABBREVIATION''' - The two letter state abbreviation (AK, CA, TX, etc.)
::'''REGION NAME''' - The full name of the region (Northwest, New England, etc.)


:'''''Second parameter'''''
:'''''Second parameter'''''
::'''state-id''' will return a URL to the state specific forum.
::'''state-id''' will return a URL to the state specific forum.
::'''region-id''' will return a URL to the forum for that state's region.
::'''region-id''' will return a URL to the forum for that state's region.
::'''region-name''' will return the name of the region, not a URL.
::'''region-name''' will return the name of the region.
::'''regional-coordinator''' will return the username of the regional coordinator.
::'''state-list''' will return the abbreviated names of the states in the region.
::'''state-list-long''' will return the full names of the states in the region.
 
 
== Examples ==
{|
| Entering:
| {{Pre2|<nowiki>
[{{StateForum | AK | state-id}} Alaska forum]</nowiki>
}}
|}
Produces: [{{StateForum | AK | state-id}} Alaska forum]
----
{|
| Entering:
| {{Pre2|<nowiki>
[{{StateForum | AK | region-id}} {{StateForum | AK | region-name}} region forum]</nowiki>
}}
|}
Produces: [{{StateForum | AK | region-id}} {{StateForum | AK | region-name}} region forum]
----
{|
| Entering:
| {{Pre2|<nowiki>
[{{StateForum | Northwest | region-id}} Northwest region forum]</nowiki>
}}
|}
Produces: [{{StateForum | Northwest | region-id}} Northwest region forum]
----
{|
| Entering:
| {{Pre2|<nowiki>
{{StateForum | Northwest | regional-coordinator}}</nowiki>
}}
|}
Produces: {{StateForum | Northwest | regional-coordinator}}
----
{|
| Entering:
| {{Pre2|<nowiki>
{{Username |{{StateForum | Northwest | regional-coordinator}} }}</nowiki>
}}
|}
Produces: {{Username |{{StateForum | Northwest | regional-coordinator}} }}
 
(NOTE: The template currently requires no space between the '''|''' and the first parameter.)
 
----
{|
| Entering:
| {{Pre2|<nowiki>
{{StateForum | Northwest | state-list}}</nowiki>
}}
|}
Produces: {{StateForum | Northwest | state-list}}
----
{|
| Entering:
| {{Pre2|<nowiki>
{{StateForum | Northwest | state-list-long}}</nowiki>
}}
|}
Produces: {{StateForum | Northwest | state-list-long}}




<includeonly>
<includeonly>
<!-- ADD CATEGORIES BELOW THIS LINE -->
<!-- ADD CATEGORIES BELOW THIS LINE -->
 
[[Category:Forum Templates]]
<!-- ADD INTERWIKIS BELOW THIS LINE -->
<!-- ADD INTERWIKIS BELOW THIS LINE -->


</includeonly>
</includeonly>

Latest revision as of 23:17, 7 July 2014

This is a documentation subpage for Template:StateForum.
It contains usage information, categories and other content that is not part of the original template page.

This template enables the automatic selection of a United States (or US Territory) forum or region name.

Usage

Place {{StateForum}} on a page where either a URL to a state or region forum is desired. Alternately the template can also determine the name of the region based on the state name or the states in a region. It uses the data in {{StateForum/List}}.

{{StateForum
| STATENAME or 
  STATE ABBREVIATION or
  REGION NAME
| state-id or 
  region-id or 
  region-name or
  regional-coordinator or
  state-list or
  state-list-long
}}

Parameters

First parameter
STATENAME - The full name of the state or territory (Alaska, California, Texas, etc.)
STATE ABBREVIATION - The two letter state abbreviation (AK, CA, TX, etc.)
REGION NAME - The full name of the region (Northwest, New England, etc.)
Second parameter
state-id will return a URL to the state specific forum.
region-id will return a URL to the forum for that state's region.
region-name will return the name of the region.
regional-coordinator will return the username of the regional coordinator.
state-list will return the abbreviated names of the states in the region.
state-list-long will return the full names of the states in the region.


Examples

Entering:
[{{StateForum | AK | state-id}} Alaska forum]

Produces: Alaska forum


Entering:
[{{StateForum | AK | region-id}} {{StateForum | AK | region-name}} region forum]

Produces: http://www.waze.com/forum/viewforum.php?f=Northwest region forum


Entering:
[{{StateForum | Northwest | region-id}} Northwest region forum]

Produces: Northwest region forum


Entering:
{{StateForum | Northwest | regional-coordinator}}

Produces: http://www.waze.com/forum/viewforum.php?f=turbomkt


Entering:
{{Username |{{StateForum | Northwest | regional-coordinator}} }}

Produces: http://www.waze.com/forum/viewforum.php?f=turbomkt (PM [Help])  

(NOTE: The template currently requires no space between the | and the first parameter.)


Entering:
{{StateForum | Northwest | state-list}}

Produces: http://www.waze.com/forum/viewforum.php?f=AK/ID/MT/OR/WA/WY


Entering:
{{StateForum | Northwest | state-list-long}}

Produces: http://www.waze.com/forum/viewforum.php?f=Alaska / Idaho / Montana / Oregon / Washington / Wyoming