Difference between revisions of "Template:Cycling Archives/doc"

From blackwiki
Jump to navigation Jump to search
imported>Zyxw
m (fix link)
imported>Zyxw
m (→‎Tracking categories: update list)
 
(3 intermediate revisions by the same user not shown)
Line 25: Line 25:
 
=== Unnamed parameters ===
 
=== Unnamed parameters ===
 
''URL:''
 
''URL:''
: <tt>[http://www.cyclingarchives.com/coureurfiche.php?coureurid=5689 http://www.cyclingarchives.com/coureurfiche.php?coureurid={{hilite|5689}}]</tt>
+
: <kbd>[http://www.cyclingarchives.com/coureurfiche.php?coureurid=5689 http://www.cyclingarchives.com/coureurfiche.php?coureurid={{hilite|5689}}]</kbd>
 
''Usage:''
 
''Usage:''
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | 5689 | Cadel Evans }}</code>
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | 5689 | Cadel Evans }}</code>
Line 33: Line 33:
 
=== Named parameters ===
 
=== Named parameters ===
 
''URL:''
 
''URL:''
: <tt>[http://www.cyclingarchives.com/coureurfiche.php?coureurid=13500 http://www.cyclingarchives.com/coureurfiche.php?coureurid={{hilite|13500}}]</tt>
+
: <kbd>[http://www.cyclingarchives.com/coureurfiche.php?coureurid=13500 http://www.cyclingarchives.com/coureurfiche.php?coureurid={{hilite|13500}}]</kbd>
 
''Usage:''
 
''Usage:''
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} |id= 13500 |name= Ellen van Dijk |accessdate= 30 March 2013 }}</code>
 
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} |id= 13500 |name= Ellen van Dijk |accessdate= 30 March 2013 }}</code>
Line 90: Line 90:
  
 
==Tracking categories==
 
==Tracking categories==
; "id" parameter exists
+
; template with ID
* {{clc|Cycling Archives template with ID same as Wikidata}}
 
 
* {{clc|Cycling Archives template with ID different from Wikidata}}
 
* {{clc|Cycling Archives template with ID different from Wikidata}}
 
* {{clc|Cycling Archives template with ID not in Wikidata}}
 
* {{clc|Cycling Archives template with ID not in Wikidata}}
; "id" parameter does not exist
+
; template missing ID
* {{clc|Cycling Archives template using Wikidata}}
 
 
* {{clc|Cycling Archives template missing ID and not in Wikidata}}
 
* {{clc|Cycling Archives template missing ID and not in Wikidata}}
  
Line 104: Line 102:
 
; Other cyclist templates
 
; Other cyclist templates
 
* [[Template:ProCyclingStats]] which uses Wikidata property {{wpl|P1663}}
 
* [[Template:ProCyclingStats]] which uses Wikidata property {{wpl|P1663}}
* [[Template:CQ ranking]] which uses Wikidata properties {{wpl|P1541}} and {{wpl|P2709}}
+
* [[Template:CQ Ranking]] which uses Wikidata properties {{wpl|P1541}} and {{wpl|P2709}}
  
 
<includeonly>{{sandbox other||
 
<includeonly>{{sandbox other||
Line 110: Line 108:
 
[[Category:Cycling external link templates]]
 
[[Category:Cycling external link templates]]
 
[[Category:People and person external link templates]]
 
[[Category:People and person external link templates]]
 +
[[Category:External link templates with accessdate parameter]]
 
[[Category:External link templates using Wikidata]]
 
[[Category:External link templates using Wikidata]]
 
[[Category:Templates that add a tracking category]]
 
[[Category:Templates that add a tracking category]]
 
}}</includeonly>
 
}}</includeonly>

Latest revision as of 00:33, 2 May 2019

Template:Uses Wikidata Template:Tracks Wikidata

Template:Cycling Archives displays an external link to a cyclist's page at the Cycling Archives website (CyclingArchives.com). It is intended for use in the external links section of an article.

Usage

Unnamed parameters:

{{Cycling Archives | ID }}
{{Cycling Archives | ID | NAME }}

Named parameters:

{{Cycling Archives | id= ID }}
{{Cycling Archives | id= ID | name= NAME }}
{{Cycling Archives | id= ID | name= NAME | accessdate= DATE }}

Using Wikidata property P1409:

{{Cycling Archives}}
{{Cycling Archives | name= NAME }}
{{Cycling Archives | name= NAME | accessdate= DATE }}

Examples

Unnamed parameters

URL:

http://www.cyclingarchives.com/coureurfiche.php?coureurid=5689

Usage:

{{Cycling Archives | 5689 | Cadel Evans }}

Output:

Cadel Evans at Cycling ArchivesScript error: No such module "EditAtWikidata".Template:WikidataCheck

Named parameters

URL:

http://www.cyclingarchives.com/coureurfiche.php?coureurid=13500

Usage:

{{Cycling Archives |id= 13500 |name= Ellen van Dijk |accessdate= 30 March 2013 }}

Output:

Ellen van Dijk at Cycling Archives. Retrieved 30 March 2013.Script error: No such module "EditAtWikidata".Template:WikidataCheck

No parameters and Wikidata property not defined

Usage:

{{Cycling Archives}}

Output:

Template:PAGENAMEBASE at Cycling ArchivesScript error: No such module "EditAtWikidata".Template:WikidataCheck

Parameters

The id parameter (or unnamed parameter 1) should contain the ID portion the URL for the cyclist's page at the Cycling Archives web site. Examples: 5689 is the ID portion of http://www.cyclingarchives.com/coureurfiche.php?coureurid=5689. This parameter is optional if Wikidata property P1409 exists, but required if not.

The name parameter (or unnamed parameter 2) may be used to specify the link text, which should be the name of the cyclist. This parameter is optional; it defaults to the Wikipedia article name, without any disambiguation such as "(cyclist)".

The accessdate parameter may be used to specify the date when the Cycling Archives profile was last accessed. This parameter is optional.

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.

TemplateData for Cycling Archives

This template displays an external link to a cyclist's page at the Cycling Archives website (CyclingArchives.com). It is intended for use in the external links section of an article.

Template parameters

ParameterDescriptionTypeStatus
IDid 1

The "id" parameter (or unnamed parameter "1") should contain the ID portion of the URL. Examples: 5689 is the ID portion of http://www.cyclingarchives.com/coureurfiche.php?coureurid=5689. This parameter is optional if Wikidata property P1409 exists, but required if not.

Default
Wikidata property P1409
Numberoptional
Namename 2

The "name" parameter (or unnamed parameter "2") may be used to specify the link text, which should be the name of the cyclist. This parameter is optional; it defaults to the Wikipedia article name, without any disambiguation such as "(cyclist)".

Default
{{PAGENAMEBASE}}
Stringoptional
Access dateaccessdate

The "accessdate" parameter may be used to specify the date when the Cycling Archives profile was last accessed. This parameter is optional.

Dateoptional

Tracking categories

template with ID
template missing ID

See also

Cycling Archives templates
Other cyclist templates