Difference between revisions of "Template:Ref"

From The Coppermind
Jump to navigation Jump to search
m (bref + {{{text}}})
(added basic documentation.)
Line 60: Line 60:
 
-->|group={{{group|{{{G|}}}|}}}<!--
 
-->|group={{{group|{{{G|}}}|}}}<!--
   
  +
-->}}</includeonly><noinclude><!-- Documentation comes bellow this line --------- -->
-->}}</includeonly><noinclude>This template helps in the creation of references by providing an interface to many of the [[Category:Link macros|link macro]] templates. It also simplifies reference reuse, by automatically giving names to references with particular characteristics.
 
   
  +
This template is meant to standardize and simplify, the referencing process for most common sources to [[Brandon Sanderson]] information. References added with template will show at the bottom of the article in the footnotes section, as usual.
 
The template encapsulate the functionality of several [[Category:Link macros|link macro]] in order to simplify reference reuse, by automatically giving names to references with particular characteristics.
  +
  +
==Detailed Usage==
  +
Generally the format to use the template is: <code><nowiki>{{Ref|First parameter|Additional arguments...}}</nowiki></code>
  +
  +
The ''First parameter'' determines which arguments should be passed after. See list of available parameters:
 
{| class=infobox width=100%
 
{| class=infobox width=100%
 
|-
 
|-
! class=title | First argument
+
! class=title | First parameter
 
! class=title | Meaning
 
! class=title | Meaning
 
! class=title | Notes
 
! class=title | Notes
Line 70: Line 77:
 
| a || Reference another wiki article || argument 3 acts as an alternative link title
 
| a || Reference another wiki article || argument 3 acts as an alternative link title
 
|-
 
|-
| b || Reference a book or chapter || 3 arguments passed to {{T|bref}}, reusable
+
| b || Reference a book or chapter || 3 arguments passed to {{T|b}}, reusable
 
|-
 
|-
 
| ? || Reference a question in Theoryland's Q&A database || 2 arguments become interwiki to the [http://www.theoryland.com/listintv.php Theoryland interview database], the third becomes the text, reusable by first 2
 
| ? || Reference a question in Theoryland's Q&A database || 2 arguments become interwiki to the [http://www.theoryland.com/listintv.php Theoryland interview database], the third becomes the text, reusable by first 2
Line 96: Line 103:
 
| map || Reference one of the map images || argument is place name and text to display
 
| map || Reference one of the map images || argument is place name and text to display
 
|}
 
|}
  +
If the first argument does not match one of the arguments in the table, the contents of the first argument are directly wrapped in ref tags.
 
  +
* For detailed instructions see the individual template pages.
{{cat|templates}}
 
 
* If the first argument does not match one of the arguments in the table, the contents of the first argument are directly wrapped in ref tags.
  +
  +
== Common Usage ==
  +
Commonly you'll be referencing books, thus the format will look similar to this: <code><nowiki>{{Ref|b|book shorthand|c|Chapter shorthand}}</nowiki></code> where:
  +
* 'b' stands for book. See list of available shorthand [[Template:B|here]].
  +
* 'c' stands for chapter, See list of variants [[Template:C|here]].
  +
  +
Practical Examples for referencing [[The Way of Kings]]:
  +
<pre>
  +
{{Ref|b|twok|c|9}} - will create a reference to "The Way of Kings, Chapter 9",
  +
{{Ref|b|twok|i|9}} - will create a reference to "The Way of Kings, Interlude 9"
  +
</pre>
  +
  +
[[Category:Templates]]

Revision as of 02:18, 11 November 2012


This template is meant to standardize and simplify, the referencing process for most common sources to Brandon Sanderson information. References added with template will show at the bottom of the article in the footnotes section, as usual. The template encapsulate the functionality of several in order to simplify reference reuse, by automatically giving names to references with particular characteristics.

Detailed Usage

Generally the format to use the template is: {{Ref|First parameter|Additional arguments...}}

The First parameter determines which arguments should be passed after. See list of available parameters:

First parameter Meaning Notes
a Reference another wiki article argument 3 acts as an alternative link title
b Reference a book or chapter 3 arguments passed to {{b}}, reusable
? Reference a question in Theoryland's Q&A database 2 arguments become interwiki to the Theoryland interview database, the third becomes the text, reusable by first 2
17s Reference a 17th Shard forum topic/post Second argument is name of third, fourth is text to display, reusable by 1 and 4
wp Reference a Wikipedia article 2 arguments, interwiki to Wikipedia
bws Reference a page on Brandons site 2 arguments, interwiki to Brandon's site
img Reference an image on the wiki arguments are file name and text to display
map Reference one of the map images argument is place name and text to display
  • For detailed instructions see the individual template pages.
  • If the first argument does not match one of the arguments in the table, the contents of the first argument are directly wrapped in ref tags.

Common Usage

Commonly you'll be referencing books, thus the format will look similar to this: {{Ref|b|book shorthand|c|Chapter shorthand}} where:

  • 'b' stands for book. See list of available shorthand here.
  • 'c' stands for chapter, See list of variants here.

Practical Examples for referencing The Way of Kings:

{{Ref|b|twok|c|9}} - will create a reference to "The Way of Kings, Chapter 9",  
{{Ref|b|twok|i|9}} - will create a reference to "The Way of Kings, Interlude 9"