Difference between revisions of "Template:LaPreferente"
imported>Zyxw (show error message if missing ID) |
imported>Zyxw (use Wikidata property if no ID in template) |
||
| (One intermediate revision by the same user not shown) | |||
| Line 1: | Line 1: | ||
| − | {{#if: {{{1 | + | {{#if: {{{1<includeonly>|</includeonly>}}} {{{id|}}} {{#property:P7359}} |
| − | | [https://www.lapreferente.com/J{{ | + | | [https://www.lapreferente.com/J{{#if: {{{1|{{{id<includeonly>|</includeonly>}}}}}} | {{{1|{{{id}}}}}} | {{First word|1={{#property:P7359}}|sep=,}} }}{{#ifeq:{{#invoke:String|find|{{{1|{{{id|<noinclude>/</noinclude><includeonly>{{First word|1={{#property:P7359}}|sep=,}}</includeonly>}}}}}}|/}}|0|/}}.html#marcoCentral {{#if: {{{2|{{{name<includeonly>|</includeonly>}}}}}} | {{{2|{{{name}}}}}} | {{PAGENAMEBASE}} }}] at LaPreferente.com {{in lang|es}}{{#if:{{{accessdate|}}}|. Retrieved {{{accessdate}}}.}}<includeonly>{{EditAtWikidata|pid=P7359|{{{1|{{{id|}}}}}}}}</includeonly> |
| − | | <span class="error">{{[[Template:LaPreferente|LaPreferente]]}} template missing ID.</span> | + | | <span class="error">{{[[Template:LaPreferente|LaPreferente]]}} template missing ID and not present in Wikidata.</span> |
}}<noinclude> | }}<noinclude> | ||
| − | {{Documentation}} | + | {{Documentation}}<!-- Please add categories to the /doc subpage & add interwikis to Wikidata. --> |
</noinclude> | </noinclude> | ||
Latest revision as of 14:54, 29 March 2020
{{{name}}} at LaPreferente.com (in Spanish)
Template:Uses Wikidata Lua error in Module:Lua_banner at line 113: attempt to index field 'edit' (a nil value).
Template:LaPreferente displays an external link to an association football (soccer) player's profile at LaPreferente.com.
Contents
Usage
- Unnamed parameters
{{LaPreferente | ID }}{{LaPreferente | ID | NAME }}
- Named parameters
{{LaPreferente | id= ID }}{{LaPreferente | id= ID | name= NAME }}{{LaPreferente | id= ID | name= NAME | accessdate= DATE }}
Examples
Unnamed parameters
- Usage
* {{LaPreferente | 112727 | Cristian Salvador }}
- Output
-
- Cristian Salvador at LaPreferente.com (in Spanish)Script error: No such module "EditAtWikidata".
- Current URLs
- https://www.lapreferente.com/index.php?IDjugador=112727
- https://www.lapreferente.com/J112727/.html
- https://www.lapreferente.com/J112727/cristian.html
- https://www.lapreferente.com/J112727/real-sporting-b/cristian.html
- Former URLs
- http://www.lapreferente.net/index.php?IDjugador=112727
- http://www.lapreferente.net/J112727/.html
- http://www.lapreferente.net/J112727/cristian.html (archive)
- http://www.lapreferente.net/J112727/real-sporting-b/cristian.html (archive)
Named parameters
- Usage
{{LaPreferente | id= 211345 | name= Juan Moreno | accessdate= 15 August 2026 }}
- Output
- Juan Moreno at LaPreferente.com (in Spanish). Retrieved 15 August 2026.Script error: No such module "EditAtWikidata".
- Current URLs
- https://www.lapreferente.com/index.php?IDjugador=211345
- https://www.lapreferente.com/J211345/.html
- https://www.lapreferente.com/J211345/juan-moreno.html
- https://www.lapreferente.com/J211345C6792/atletico-de-madrid/juan-moreno.html
- Former URLs
- http://www.lapreferente.net/index.php?IDjugador=211345
- http://www.lapreferente.net/J211345/.html
- http://www.lapreferente.net/J211345/juan-moreno.html
- http://www.lapreferente.net/J211345C6792/atletico-de-madrid/juan-moreno.html
No parameters and Wikidata property not defined
- Usage
* {{LaPreferente}}
- Output
-
- Template:PAGENAMEBASE at LaPreferente.com (in Spanish)Script error: No such module "EditAtWikidata".
TemplateData
TemplateData for LaPreferente
This template displays an external link to an association football (soccer) player's profile at LaPreferente.com.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| ID | id 1 | The "id" parameter (or unnamed parameter "1") should contain the ID portion of the URL. Example: 112727 is the ID portion of https://www.lapreferente.com/index.php?IDjugador=112727 or https://www.lapreferente.com/J112727/real-sporting-b/cristian.html. This parameter is optional if Wikidata property P7359 exists, but required if not.
| Number | optional |
| Name | name 2 | The "name" parameter (or unnamed parameter "2") may be used to specify the link text, which should be the name of the player. This parameter is optional; it defaults to the Wikipedia article name, without any disambiguation such as "(footballer)" or "(soccer)".
| String | optional |
| Access Date | accessdate | The "accessdate" parameter may be used to specify the date when the URL was last accessed. This parameter is optional. | Date | optional |
See also
| The above documentation is transcluded from Template:LaPreferente/doc. (edit | history) Editors can experiment in this template's sandbox (edit | diff) and testcases (create) pages. Please add categories to the /doc subpage. Subpages of this template. |