Help:League-season pages

From SABR Encyclopedia

Revision as of 16:51, 29 April 2010 by GarverP01 (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

A League-season page contains information on one league's activity in one baseball season. An example is 2009 American League.

Contents

[edit] Form:League-season

This form directly edits these templates:

The form has three tabs, and a total of three editable fields.

[edit] Info

This tab contains properties that are displayed in the infobox, which differentiates them from the "System Properties" which are not visible on the page.

  • Logo – can be edited by anyone. Should contain the name of a file stored in the wiki.
  • Year – restricted, edited by bot only.
  • Full name – restricted, edited by bot.
  • Classification – restricted, edited by bot.
  • Short name – restricted, edited by bot.

[edit] Article text

This tab contains the Article text, which is "Free text" that falls outside of any templates.

It also contains "sources", which is the first field of the "League-season-bottom" template. The template continues to the next tab

[edit] System properties

All properties are protected.

  • SABR Database key – The primary key of the league in the main database. Used to link to stats queries, and set as a semantic property that allows a bot to find this page.
  • Other names – Other names commonly used for the league, to be used in search. A semicolon-separated list.
  • Index terms – A list of index terms to be used for search. This property is common to all structured pages.
  • Main league page – The main page for the league in a multi-year, historical context. For example, American League. This value is also used to generate the name of the league sidebar, which should be [[Template:(main league page) sidebar]]. For example, [[Template:American League sidebar]].

[edit] Template:League-season-top

This template draws the infobox and sets properties contained in the "Info" tab of the form, then displays the League-season-stats-box template (see below).

[edit] Infobox

  • Header: Year (with link to year page) full league name
  • Logo (if exists), 240px wide with border. Standard infobox logo style.
  • Classification (if set)

[edit] Semantic properties

Silently sets the following semantic properties, if values are present:

  • Property league-season-year is set to the parameter year.
  • Property league-season-name-full is set to the parameter name_full.
  • Property league-season-name-short is set to the parameter name_short.
  • Category assignment? None currently.

[edit] Template:League-season-stats-box

This template gets the league's SABR Key by querying the semantic property, then displays a right-floated box which currently contains links to these categories of statistics:

  • Individual batting
  • Individual pitching

The links are to complete html pages, which are popped up in floatboxes. Visitors with javascript disabled will go forward to the pages, which will still display correctly.

[edit] Template:League-season-bottom

This template:

  • Displays sources (adding a second-level heading) if any exist in the parameter sources.
  • Inserts the <references /> tag, which works whether or not there are any references.
  • Displays the League-season-details template (see below).
  • Displays the "Profesionnal leagues in (year) navbox" if it exists, by querying for the year as a semantic property.
  • Sets the system properties silently.

[edit] Semantic properties

  • Property league-key-sabr is set to the parameter key_sabr.
  • Property League-season-name-alias is set to the list in name_alias', which is split on semicolons using the #arraymap parser function.
  • Property Page-indexterm is set to the list in indexterms, which is split on semicolons using the #arraymap parser function.

[edit] Template:League-season-details

This template uses the navbox template to display the results of two semantic queries:

  • Clubs – a list of clubs with:
    • their team-season-year equal to this page's league-season-year, and
    • their team-season-league-name-short equal to this page's league-season-name-short.
  • Umpires – a list of umpires with person-umpired-in set to this pagename.

[edit] Template:Professional leagues in (year) navbox

This template is deprecated, to be replaced with a single template that queries for the year and displays a navbox automatically. This page will be updated when it is.

Personal tools