Template:Wikidata link
| This template uses Lua: |
A template to create a link to either Wikisource, Wikipedia, Commons, or Reasonator.
Using the specified Wikidata QID, the template checks for the existence of other sitelinks (in this order: en.Wikisource, en.Wikipedia, and Wikimedia Commons) and if one is found links to it. If none is found, it links to Reasonator's human-friendly representation of the item in Wikidata.
Usage
[edit]Please refer to Wikisource:Annotations before using this template in the Page: namespace or in the Mainspace.
| Description | Wikitext | Output |
|---|---|---|
| Simple usage: Wikidata item that is linked to a Wikipedia article | {{wikidata link|Q42}} | Douglas Adams |
| Shortened form: identical behavior, but shorter to type | {{wdl|Q42}} | Douglas Adams |
| Wikidata item that is linked to a Wikisource author page | {{wdl|Q60727470}} | Alfred Cooper Fryer |
| Wikidata item that is linked to a Wikisource work page | {{wdl|Q1147121}} | The Devil's Dictionary |
| Wikidata item with neither a Wikipedia nor a Wikisource link | {{wdl|Q54856396}} | Fonts with Representations of the Seven Sacraments: Supplement |
| Customized link label | {{wdl|Q42|Mr Adams}} | Mr Adams |
Visibility of links
[edit]The link color is currently enabled by default. You can disable it with the Visibility gadget.
Templatedata
[edit]Link to Wikisource, Wikipedia, Commons, or Reasonator, depending on the sitelinks of the given Wikidata item.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| Wikidata ID | 1 | The Q-number of the item. | String | required |
| Link text | 2 | The text that will be displayed as the link. | String | suggested |
See also
[edit]- {{Annotate QID}}
- {{Scholia}}
- {{Wikidata entity link}}
- {{Wikidata property link}}
- Module:Wikidata link