Template:Refbegin/doc

Refbegin and its complementary closing template refend are used to apply any of several optional styles or presentational choices for bibliographies or reference lists&mdash;that is, lists of fully-specified references / sources / works cited, alpha-sorted by author/contributor) that appear in wikipedia articles.

These bibliographies or reference lists frequently appear in dedicated sections within an article, variously titled ==References==, ==Works cited==, ==Bibliography==, ==Further reading==, ==Published works==, and so on.

Wikipedia referencing or citation systems that use bibliography-style reference lists include: 'shortened' footnotes, parenthetical referencing, and 'general' referencing. The 'full' footnote and embedded citations referencing systems do not use those lists, although articles using these latter two systems may also contain "Further reading" or other sections containing bibliography-style listings, that refbegin formatting could be applied to.

The formatting options provided by this template are: Each use of refbegin whether with or without parameters, needs an accompanying refend closing template to 'turn off' the formatting; refend does not need any parameters.

Font size reduction is always applied. Either one, the other, or both of multi-columns and hanging indent may be applied as well (though see specifics and caveats on browser differences in relevant sections, below).

Usage
With all (optional) parameters shown:

Placement
The refbegin is placed immediately below the header of the bibliography/references section its formatting will be applied to. The closing refend template is placed within the same section, at the end of the bibliography/references list content.

When used, each occurrence of refbegin should always be paired with a corresponding closing refend template:

Option 1: Text size (default behaviour)
The default usage (without parameters) applies a style that reduces the text size of the bibliographies/reference list entries. This can be useful to make a long bibliography/list of references display more compactly, and it also mimics the formatting style applied to footnotes by the reflist template.

The reflist formats footnotes—any text in the article body that is placed between  tags—that are auto-generated by the cite.php extension, called by reflist. In the case of articles using the 'shortened' footnotes referencing system, these footnotes will typically contain an abbreviated citation such as   that corresponds with an entry in the bibliography/references list section (other text such as discursive notes may appear as well).

The font size should reduce to 90% for most browsers, but may appear to show at 100% for Internet Explorer and possibly other browsers. Reflist uses one CSS entry in MediaWiki:Common.css to set the font size:



Editors may over-ride this setting by placing entries in their personal CSS.

The left margin will be indented by 1.5em as well, aligning with the margin produced by reflist.

If the 'full' footnotes referencing system is used (ie there is no separate bibliography/references list, all cites/references are defined in  tags), then use reflist alone:

Option 2: Multiple columns
If an integer n is supplied as the first parameter, the template will display the bibliography/references list in n columns. This may be useful for compact display for a lengthy list, and matches also the optional capability of reflist to display output in multiple columns. Thus, will display the list in two columns. If no integer parameter is specified, the default is a single column.

Note, it will rarely be useful or practical to display bibliography/references list entries in more than two columns.

Browser support
Multiple columns are generated by using CSS3, which is still in development; thus only browsers that properly support the multi-column property will show multiple columns.
 * Mozilla Firefox and other Gecko-based browsers support multiple columns, but may create widows
 * Internet Explorer through version 8 does not currently support the column selector
 * Safari, Google Chrome and probably other WebKit based browsers have a bug that breaks links in multiple columns; WebKit support is removed in reflist for this reason, but is enabled in refbegin as such links will usually not be used in bibliographies
 * Opera does not support multiple columns

Option 3: Hanging indentation
A hanging indentation may be applied to bibliographies/reference lists by using the indent parameter. This option can be useful in long bibliographies/reference lists and in particular when individual entries in the list are long, ie they wrap over more than one line in the browser display window. Applying a hanging indent to the list makes it much easier to distinguish the keywords (ie normally the authors' names) in the bibliography and makes the stand out from preceding and succeeding lines of text. Hanging indents in bibliographies also form part of several widely used citation style implementations, such as APA, MLA, and Chicago.

Do not use indent in conjunction with columns. The With FireFox and other Gecko-based browsers, the first line of each entry in the successive columns will overlap the previous column. With Safari, Chrome and other WekKit-based browsers, the first line will be clipped at the margin.

To use, set  .

Note, owing to differences between browsers in the way they display bullet markers, if the |indent=yes option is used it is recommended to replace the bullet markers (asterisk [*]) with a 'non-bullet' marker (colon [:]), or else in some browsers the bullet marker will be indented up against the text.

Alternatively, omit bullets in the list altogether but separate each list entry with a blank line.


 * Examples
 * a) Using refbegin but without the hanging indent option applied:-


 * References




 * b) Using refbegin with the hanging indent option |indent=yes applied:-


 * References




 * c) Using indent in combination with multi-column (in this case, n=2) display [NB mutlicolumn only works in some browsers]:-


 * References