Template:Reflist: Difference between revisions

m
Protected "Template:Reflist": high traffic page ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite))
m (1 revision: Yayz)
m (Protected "Template:Reflist": high traffic page ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)))
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<div class="references-small" {{#if: {{{colwidth|}}}| style="-moz-column-width:{{{colwidth}}}; -webkit-column-width:{{{colwidth}}}; column-width:{{{colwidth}}};" | {{#if: {{{1|}}}| style="-moz-column-count:{{{1}}}; -webkit-column-count:{{{1}}}; column-count:{{{1}}} }};" |}}>
<includeonly><div class="reflist" style="{{#if:{{{1|}}}|column-count:{{{1}}}|{{#if:{{{colwidth|}}}|column-width:{{{colwidth}}}}}}}">
<references /></div><noinclude>
{{#tag:references||group={{{group|}}}|responsive={{#if:{{{1|{{{colwidth|}}}}}}|0}}}}</div></includeonly><noinclude>
== Usage ==
== Usage ==
Use this template to create a reference list in an article with a small font.
Use this template to add a list of references and citations to an article's "References" section.


Using <tt><nowiki>{{reflist|2}}</nowiki></tt> will create a two-column reference list, and <tt><nowiki>{{reflist|3}}</nowiki></tt> will create a three-column list.
=== Automatic mode ===
Using <code><nowiki>{{reflist}}</nowiki></code> will create a single-column list if there are 10 references or fewer, and a responsive multi-column list if there are more than 10 items. The number of columns will vary depending on the browser's width.


Using <tt><nowiki>{{reflist|colwidth=30em}}</nowiki></tt> will allow the browser to automatically choose the number of columns based on the width of the web browser.  Choose a column width that's appropriate for the average width of the references on the page.
=== Specific parameters ===
Using <code><nowiki>{{reflist|2}}</nowiki></code> will create a two-column reference list, and <code><nowiki>{{reflist|3}}</nowiki></code> will create a three-column list.


Note: multiple columns currently render properly only in Mozilla Firefox and other Gecko-based browsers, though the feature is included in CSS3, so it should work for a larger number of browsers in the future.
Using <code><nowiki>{{reflist|colwidth=30em}}</nowiki></code> will allow the browser to automatically choose the number of columns based on the width of the web browser. Choose a column width that's appropriate for the average width of the references on the page.


[[Category:Reference templates|{{PAGENAME}}]]
[[Category:Reference templates]]</noinclude>
</noinclude>