Template:Reflist: Difference between revisions

From The Evanescence Reference
No edit summary
No edit summary
Line 39: Line 39:
<code><nowiki>{{Reflist|group=groupname}}</nowiki></code>
<code><nowiki>{{Reflist|group=groupname}}</nowiki></code>


Where groupname is a group identifier such as "notes", "nb" or "label". Make sure to put <code><nowiki>{{Reflist|group=groupname}}</nowiki></code> '''''before''''' the general <code><nowiki>{{Reflist}}</nowiki></code>.
Where groupname is a group identifier such as "notes", "nb" or "label". For example:
 
<pre><nowiki>Frog note.<ref name=note group=note>Note content.</ref>
 
== Notes ==
{{Reflist|group=note}}</nowiki></pre>
 
Make sure to put <code><nowiki>{{Reflist|group=groupname}}</nowiki></code> '''''before''''' the general <code><nowiki>{{Reflist}}</nowiki></code>.


=== Columns ===
=== Columns ===

Revision as of 04:43, 27 August 2013

This citation template provides formatting and organizational features for footnotes. It encapsulates the <references /> tag used by the Cite.php MediaWiki extension to show the list of references as defined by <ref> tags. It adds support for a reduced font size, columns, groups and list-defined references.

Usage

Font

{{Reflist}} uses a CSS rule in MediaWiki:Common.css to set the font size:

  • div.reflist { font-size: 94%; }

Grouped references

As of June 2008, the footnotes system supports the separation of references into groups. This allows groups for explanatory notes, table references and the like.

The general format for the reference tag is:

<ref group=groupname>

And using |group= for the reflist:

{{Reflist|group=groupname}}

Where groupname is a group identifier such as "notes", "nb" or "label". For example:

Frog note.<ref name=note group=note>Note content.</ref>

== Notes ==
{{Reflist|group=note}}

Make sure to put {{Reflist|group=groupname}} before the general {{Reflist}}.

Columns

Using {{Reflist|2}} will create a two-column reference list, and {{Reflist|3}} will create a three-column list, and so on. Choose the number of columns that is appropriate for the average width of the references on the page.

Using {{Reflist|30em}} will create columns with a minimum width of 30 em, allowing the browser to automatically choose the number of columns based on the width of the web browser. Choose a column width that is appropriate for the average width of the references on the page.

List-defined references

List-defined references use named references where each individual reference has a unique name and is defined within the reference list markup:

<references>
<ref name=name>reference</ref>
</references>
Or; using {{Reflist}}
{{reflist|refs=
<ref name=name>reference</ref>
}}

Each reference is invoked in the article using <ref name=name />.

  • List-defined references and references defined in the body of the article should not be mixed on a page, as it may be confusing to ongoing editors.
  • All list-defined references must be named. A well-used practice is author-date, author-title or publication-date.
  • All list-defined references must be used in the body. Unused references will generate an error.