![]() | This template is used on approximately 2,300 pages and changes may be widely noticed. Test changes in the template's /sandbox or /testcases subpages, or in your own user subpage. Consider discussing changes on the talk page before implementing them. |
![]() | This template uses TemplateStyles: |
For some atypical citations, {{Wikicite}} can create an HTML anchor. When used in manually written, non-templated full citations, it allows shortened footnotes to link to the full citation on the same page. The link anchor can work with short-citation templates, such as {{sfn}}
, {{harvnb}}
, {{sfnp}}
, {{harvp}}
, and others.
This template is only needed for a handwritten citation or for a citation using non-standard citation templates, that is linked to by a shortened footnote. The anchor serves no purpose if nothing links to it, and full citations created with the common {{cite xxx}} templates will either automatically create the anchor or offer the |ref=
parameter for custom link anchors. In most cases, this template is expected to be used temporarily, in cases where an editor is not certain how to format the full citation data into a template, does not have time to do it, where there is a dispute on the talk page about which citation format should be used, or where a specific citation template does not yet support the |ref=
parameter. In a handful of cases, however, there remain some articles with local consensus to use entirely manually formatted citations, to exactly mirror some off-site citation style. This is rare but permitted by the WP:CITESTYLE guideline.
Usage
Copy and paste:
{{wikicite |ref={{sfnref|}} |reference= }}
or
{{wikicite |ref= |reference= }}
- ref
- This creates the invisible HTML anchor. It can be used with the anchor template {{sfnref}} or its alias {{harvid}}. Both of those templates accept the same parameters as shortened footnote templates. The parameter can also be used with a freeform anchor and manually written anchor links. Compared to citation style 1 templates, such as {{cite web}} or {{cite book}}, the anchor is rather arbitrary, but it is best if the parameters match the citation data exactly (including precise author name spellings and order), since someone might template the manually formatted citation, which would auto-generate citation anchor data that could then be used with the same short-citation templates without them having to be updated.The anchor can be enclosed in quotation marks, but these are optional unless the anchor contains any character other than a number, letter, or hyphen. For example, with a space, a ref anchor of Von Autor-2006 must be specified as
|ref="Von Autor-2006"
. - reference
- The actual reference text. It may be plain text, formatted text, or one of the citation templates.
Examples
In the following examples from the Bengal famine of 1943, an unpublished but publicly available manuscript by the Indian Government’s Regional Food Commissioner is used as a primary source. As there are few acceptable places on Wikipedia to use an unpublished memoir as a source, no citation template directly matches the document:
Markup | Renders as |
---|---|
Government sources privately admitted the shortfall was 2 million tons.{{sfn|Braund|1944|p=50}} ==Notes== {{reflist}} ==References== * {{wikicite | ref = {{sfnref|Braund|1944}} | reference = Braund, H. B. L. (1944). ''Famine in Bengal'', typescript. British Library Doc D792.}} |
Government sources privately admitted the shortfall was 2 million tons.[1] Notes
References
|
You can also provide the |ref=
parameter with a free-form anchor. The anchor can contain letters, numbers, and hyphens. To link to a free-form anchor, use a wikitext anchor link. For example, link to {{wikicite |ref=Doe-1999 |reference=... }}
with <ref>[[#Doe-1999|Doe 1999]], p. x.</ref>
. Below, the previous example has been rewritten with a free-form anchor:
Markup | Renders as |
---|---|
Government sources privately admitted the shortfall was 2 million tons.<ref>[[#Braund-1944|Braund (1944)]], p. 50</ref> ==Notes== {{reflist}} ==References== * {{wikicite | ref = Braund-1944 | reference = Braund, H. B. L. (1944). ''Famine in Bengal'', typescript. British Library Doc D792.}} |
Government sources privately admitted the shortfall was 2 million tons.[1] Notes
References
|
Non-standard templates
Most citation templates have a |ref=
parameter that can accept any anchor, similar to the |ref=
parameter in this template. Templates that don't support this can be placed into this template's |reference=
parameter:
* {{wikicite |ref={{Harvid|Australian Recording Industry Association A}} |reference= {{cite certification|region=Australia|certyear=2006|access-date=1 July 2019}} }}
When the citation template is updated to generate its own anchor, the custom anchor can be moved from {{wikicite}} to the citation template:
* {{cite certification|region=Australia|certyear=2006|access-date=1 July 2019 |ref={{Harvid|Australian Recording Industry Association A}} }}
Backward compatibility with id
The |id=
parameter can also be used to create an HTML anchor in a full citation. It has the same role as the |ref=
parameter but they work in slightly different ways. If both |id=
and |ref=
are provided, |id=
is ignored. There are two differences:
|id=
automatically prefixes the link anchor with "Reference-", whereas|ref=
does not.|id=
encloses the link anchor in double quotes, so these must not be provided by the editor.
Thus, these two forms produce identical results:
{{wikicite | id = Anchor 1 | reference = Reference text }}
{{wikicite | ref = "Reference-Anchor 1" | reference = Reference text }}
The |id=
parameter can only be used with manual anchor links:
Markup | Renders as |
---|---|
According to Atwood, blah blah.<ref>[[#Reference-Atwood-2003|Atwood (2003)]], p. 29.</ref> == Notes == {{reflist}} == References == * {{wikicite | id = Atwood-2003 | reference = Atwood, Margaret (2003). ''Oryx and Crake'', Toronto: McClelland & Stewart. {{ISBN|978-0-7710-0868-9}}. }} |
According to Atwood, blah blah.[1] Notes
References
|
Template data
TemplateData for Wikicite
No description.
Parameter | Description | Type | Status | |
---|---|---|---|---|
1 | 1 | no description | Unknown | optional |
ref | ref | no description | Unknown | optional |
id | id | no description | Unknown | optional |
reference | reference | no description | Unknown | optional |
See also
- {{Citation}}
- {{Harvnb}}
- {{Sfn}}, an alternative method for creating shortened footnotes
- {{Citeref}}, alternative method to create links to citations
- Wikipedia:Citation templates
- Wikipedia:Citing sources
- Wikipedia:Citing sources/Further considerations#Using Wikicite
- T-34#References, example of usage