Wikipedia:WikiProject Golf/Templates
From Wikipedia, the free encyclopedia
WikiProject Golf |
|
Main pages(edit · changes) | |
Main project | talk |
Golf portal | talk |
Article Assessment Statistics | |
Core Articles | talk |
Members | |
Requested Golf articles | talk |
Departments | |
Assessment | |
Outreach | |
Other | |
To-Do List | |
Recent Updates | |
Featured/Good Articles | |
Categories | |
Templates | talk |
Articles for Deletion | talk |
This page is part of the WikiProject on Golf and is intended to be used as a guide on template standardization.
Contents |
[edit] Navigational boxes (navboxes)
This is a system for allowing all navigational boxes related to Golf to be placed on any page without having to have them as separate boxes, thus making it simple to, for example (unrealistic as it may be), group into one navbox the listings of all the tours and major championships and other navboxes used. Standard colours for header rows, standard methods for listing teams, and other standardizations have been introduced to make these boxes look good when combining several different pieces.
[edit] Templates used
The standardization consists of four templates, and only needs minor modification of the existing navboxes to work.
- {{golf box start}}
- {{golf box end}}
- {{golf box inner start}}
- {{golf box inner end}}
[edit] If the navbox is standardized
If the navbox you intend to include in an article already standardized (there may be a text at the template page saying so, but if there is not, test this by simply adding it to an article and preview, if this produces strange results, it is standardized, if it shows up as it should, it is not standardized), the only thing you need to do to include it in the article is to type in:
{{golf box start}}
{{Golf template}}
{{golf box end}}
Of course replacing {{Golf template}} with the navbox you intend to use. If there already are {{golf box start}} and {{golf box end}} tags included in the article, just place {{Golf template}} somewhere in between them, there is no need for double sets of tags:
{{golf box start}}
{{Golf template}}
{{Another Golf template}}
{{golf box end}}
[edit] If the navbox is not standardized
If the navbox you intend to include in an article is not standardized, a few modifications to the navbox are necessary if you want to use it with the {{golf box start}} and {{golf box end}} tags. In case you are a lazy Wikipedian, just add the template the regular way without modifying anything, but in case you are a good Wikipedian, do the following:
- Open up and edit the navbox page.
- Add the following at the absolute top of the navbox:
<noinclude>{{golf box start}}</noinclude>
This ensures that the template page of the navbox shows how the navbox looks when used instead of showing the code. - Add the following under the previous code:
|-
!style="background:#ccccff;"|{{Tnavbar-header|[[Navbox header]]|Template Name|bgcolor=#ccccff}}
This produces the header of the navbox, with the standard colour, which may be changed when making for example club navboxes, but otherwise this colour (light purple) should be used for most templates. It also includes small links to template, template talk and edit template. The [[Navbox header]] should of course be modified to fit the purpose of the navbox you are creating/standardizing, but Template Name must be the exact name used after Template: in the title. - Add the following under the previous code:
{{golf box inner start}}
This is a short piece of code that allows all kinds of navbox configurations to be displayed between the same {{golf box start}} and {{golf box end}} tags. - Next add the contents of the navbox. When creating/standardizing a navbox listing things, the standard code is:
|- style="text-align:center;"
|
<!-- NBSPs prevent wrapping-->
[[First item|First item]] |
[[Second item|Second item]] |
...
[[Last item|Last item]]
When creating/standardizing a navbox with tables, the standard code is:
|- style="text-align:center;"
|width="xx%"|[[1st row, 1st col]]
|width="xx%"|...
|width="xx%"|[[1st row, Last col]]
|- style="text-align:center;"
|[[2nd row, 1st col]]
|...
|[[2nd row, Last col]]
And so on. - Add the following under the previous code:
{{golf box inner end}}<noinclude>
{{golf box end}}
{{using golf box}}</noinclude>
The first tag is the ending of the earlier {{golf box inner start}}, the second tag is the ending of the earlier {{golf box start}} and the last tag adds a short explanation on how to use the template and also adds it in this category.
This should work on all navboxes that only contain one header and one type of formatting (listing or tables, not both). If the navbox is more complicated than that, you may either fiddle around a little yourself if you are confident in that you understand the use of the templates, or contact someone that can help you, preferably by asking on this page's talk page.
[edit] Information boxes (infoboxes)
Code | Where to use | Usage instructions |
---|---|---|
{{Infobox golfer}} | Biographies of golfers | Template talk:Infobox golfer |
{{Infobox Golf Tournament}} | Articles about golf tournaments | Template talk:Infobox Golf Tournament |
{{Infobox Golf Facility}} | Articles about golf courses | Template talk:Infobox Golf Facility |
{{Infobox Former Golf Tournament}} | Articles about former golf tournaments | Template talk:Infobox Former Golf Tournament |
[edit] Scorecard Templates
- {{Golf18}} (row of holes 1–18)
Go to Torrey Pines Golf Course for a good example on how to use these templates.
[edit] Golf Tours
- {{Champions Tour}}
- {{Champions Tour seasons}}
- {{Golf Tourny}} (PGA Tour)
- {{European Tour}}
- {{Former European Tour Events}} (Former events)
- {{European Seniors Tour}}
- {{Footer WomensMajors}} (only for Womens majors at the moment)
[edit] Tournaments
[edit] Mens major golf chmpionships
- {{The Masters champions}}
- {{U.S. Open champions}}
- {{The Open champions}}
- {{PGA Champions}}
- {{Masters Tournaments}}
- {{U.S. Open Golf Championships}}
- {{The Open Championships}}
- {{PGA Championship}}
[edit] Womens major golf championships
- {{U.S. Women's Open Champions}}
- {{LPGA Champions}}
- {{Women's British Open Champions}}
- {{Dinah Shore/Nabisco Champions}}
[edit] Other
[edit] Team Tournaments
- {{Ryder Cup Squad 2004}}
- {{Ryder Cup Squad 2004 America}}
- {{Ryder Cup Squad 2006 Europe}}
- {{Ryder Cup Squad 2006 America}}
[edit] Individual Achievements
- {{PGA Players of the Year}}
- {{PGA Tour Rookie of the Year}}
- {{Male golfers who have won 2 or more Major Championships in one year}}
- {{European Tour Order of Merit winners}}
- {{Sir Henry Cotton Rookies of the Year}}
[edit] Stub Notices
Listed below are the specific stub notices that can be used for stub articles
Code | What it looks like | Where to use |
---|---|---|
{{Golf-stub}} | On stub articles about Golf. | |
{{Golfcourse-stub}} | On stub articles about Golf courses. | |
{{golf-bio-stub}} | On stub articles about Golfers. |
[edit] Talk page templates
These should be only used on talk pages.
Code | What it looks like | Where to use |
---|---|---|
{{Wikiproject Golf}} | On talk pages of golf articles. |