Template:Cite Q/sandbox
| This is the template sandbox page for Template:Cite Q (diff). |
| This template is used on approximately 42,000 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. |
| From the TfD closure: "Until the matter of transcluding Wikidata on Wikipedia is resolved (most likely with a huge and contentious RFC) usage of this template should be extremely vetted to ensure that all of the transcluded information is accurate." |
| This template uses Lua: |
Purpose
This template returns a formatted citation from statements stored on a Wikidata item (referred to by its Q identifier or QID) describing a citable source such as a scholarly article.
For example, Wikidata item Script error: The module returned a nil value. It is supposed to return an export table. (Q15625490) is a scholarly item. To cite this as a source:
You can read about the template in:
- No label or title -- debug: Q104831003, Wikidata Q104831003
Note: While Wikipedia does not regard Wikidata as a reliable source, citations using Cite Q are not citing Wikidata; they cite the individual work stated, using metadata about that work, which is held on Wikidata for convenience.
Usage
A wrapper for {{Citation}}, which calls available values from Wikidata.
An example of an article using this template for all of its references is South Pole Telescope; an example using Harvard style citations is Suffix automaton.
By default, if there are more than eight author names, the template displays three, followed by "et al". This can be changed using |display-authors=; setting that parameter to all displays them all. The same applies to multiple editors – see the test-case pages.
Citations of papers which have been retracted (Script error: The module returned a nil value. It is supposed to return an export table. (P5824)) will appear in Category:Cite Q - cites a retracted work.
Citations of papers which have been replaced (Script error: The module returned a nil value. It is supposed to return an export table. (P1366)) will appear in Category:Cite Q - cites a replaced work.
You can also use {{Cite Q bulleted}} if you want to have a bullet returned before the citation (useful for automatic lists)
Parameters
|1== Wikidata QID for the article
Additionally, any named parameter used in {{citation}} may be entered and will overwrite the value in Wikidata. Using such parameters, with a value of unset, will suppress display of data from Wikidata.
Blank
<ref name="">{{Cite Q| XXQIDXX }}</ref>
Reference naming
For ease of use, you may wish to name your references to reflect the cited work, for example:
<ref name="Williams-2010">{{Cite Q|Q15625490}}</ref>
Parameter / entity map
This section lists where each of the template's supported parameters gets its data.
Bibliographic parameters
|at== Script error: The module returned a nil value. It is supposed to return an export table. (P958)|authorn== Script error: The module returned a nil value. It is supposed to return an export table. (P50); Script error: The module returned a nil value. It is supposed to return an export table. (P2093)|chapter== Script error: The module returned a nil value. It is supposed to return an export table. (P792)|edition== Script error: The module returned a nil value. It is supposed to return an export table. (P393)|editorn== Script error: The module returned a nil value. It is supposed to return an export table. (P98); Script error: The module returned a nil value. It is supposed to return an export table. (P5769)|issue== Script error: The module returned a nil value. It is supposed to return an export table. (P433)|journal== Script error: The module returned a nil value. It is supposed to return an export table. (P1433)|language== Script error: The module returned a nil value. It is supposed to return an export table. (P407)|pages== Script error: The module returned a nil value. It is supposed to return an export table. (P304)|place== Script error: The module returned a nil value. It is supposed to return an export table. (P1071) (for written-at place)|publication-date== Script error: The module returned a nil value. It is supposed to return an export table. (P577) (treated like|date=unless both are given)|publication-place== Script error: The module returned a nil value. It is supposed to return an export table. (P291) (for publication place, treated like|place=unless both are given)|publisher== Script error: The module returned a nil value. It is supposed to return an export table. (P123)|series== Script error: The module returned a nil value. It is supposed to return an export table. (P179)|title== Script error: The module returned a nil value. It is supposed to return an export table. (P1476) (Wikidata label)|translatorn== Script error: The module returned a nil value. It is supposed to return an export table. (P655)|url== Script error: The module returned a nil value. It is supposed to return an export table. (P953), Script error: The module returned a nil value. It is supposed to return an export table. (P856), Script error: The module returned a nil value. It is supposed to return an export table. (P2699)|version== Script error: The module returned a nil value. It is supposed to return an export table. (P348)|volume== Script error: The module returned a nil value. It is supposed to return an export table. (P478)|others== Script error: The module returned a nil value. It is supposed to return an export table. (P86), Script error: The module returned a nil value. It is supposed to return an export table. (P110), Script error: The module returned a nil value. It is supposed to return an export table. (P2679), Script error: The module returned a nil value. It is supposed to return an export table. (P371), Script error: The module returned a nil value. It is supposed to return an export table. (P175)
Identifier parameters
|asin== Script error: The module returned a nil value. It is supposed to return an export table. (P5749) (add|asin-tld=for some locales)|arxiv== Script error: The module returned a nil value. It is supposed to return an export table. (P818)|bibcode== Script error: The module returned a nil value. It is supposed to return an export table. (P819) (add|bibcode-access=to indicate free)|biorxiv== Script error: The module returned a nil value. It is supposed to return an export table. (P3951)|citeseerx== Script error: The module returned a nil value. It is supposed to return an export table. (P3784)|doi== Script error: The module returned a nil value. It is supposed to return an export table. (P356) (add|doi-access=to indicate free; add|doi-broken-date=if deprecated)|hdl== Script error: The module returned a nil value. It is supposed to return an export table. (P1184) (add|hdl-access=to indicate free)|isbn== Script error: The module returned a nil value. It is supposed to return an export table. (P212) (falls back to Script error: The module returned a nil value. It is supposed to return an export table. (P957))|ismn== Script error: The module returned a nil value. It is supposed to return an export table. (P1208)|issn== Script error: The module returned a nil value. It is supposed to return an export table. (P236)|jstor== Script error: The module returned a nil value. It is supposed to return an export table. (P888) (add|jstor-access=to indicate free)|lccn== Script error: The module returned a nil value. It is supposed to return an export table. (P1144)|mr== Script error: The module returned a nil value. It is supposed to return an export table. (P889)|oclc== Script error: The module returned a nil value. It is supposed to return an export table. (P243)|ol== Script error: The module returned a nil value. It is supposed to return an export table. (P648) (add|ol-access=to indicate free)|osti== Script error: The module returned a nil value. It is supposed to return an export table. (P3894) (add|osti-access=to indicate free)|pmc== Script error: The module returned a nil value. It is supposed to return an export table. (P932) (add|pmc-embargo-date=if embargoed)|pmid== Script error: The module returned a nil value. It is supposed to return an export table. (P698)|rfc== Script error: The module returned a nil value. It is supposed to return an export table. (P892)|ssrn== Script error: The module returned a nil value. It is supposed to return an export table. (P893)|s2cid== Script error: The module returned a nil value. It is supposed to return an export table. (P8299) (add|s2cid-access=to indicate free)|zbl== Script error: The module returned a nil value. It is supposed to return an export table. (P894)