Difference between revisions of "Template:IBDB name/doc"

From blackwiki
Jump to navigation Jump to search
imported>Ahecht
(Update for new IBDB page name format)
imported>Zyxw
(update usage, examples, TemplateData)
Line 1: Line 1:
 
{{Documentation subpage}}
 
{{Documentation subpage}}
 +
<!--Categories where indicated at the bottom of this page, please; interwikis at Wikidata (see [[Wikipedia:Wikidata]])-->
 
{{Uses Wikidata|P1220}}
 
{{Uses Wikidata|P1220}}
 
{{Tracks Wikidata|P1220}}
 
{{Tracks Wikidata|P1220}}
<!--Categories where indicated at the bottom of this page, please; interwikis at Wikidata (see [[Wikipedia:Wikidata]])-->
 
  
This template generates an external link to a page at the [[Internet Broadway Database]]. This template '''should be used exclusively for ''PEOPLE'''''.
+
'''{{NAMESPACE}}:{{BASEPAGENAME}}''' displays an external link to a web page at the [[Internet Broadway Database]] (IBDB), operated by the [[The Broadway League]]. This template '''should be used exclusively for ''people'''''. It is intended for use in the [[Wikipedia:External links|external links]] section of an article.
  
If you need to link a show, use [[Template:IBDB title]] instead.
+
If you need to link a show, use [[Template:IBDB show]] or [[Template:IBDB title]] instead.
  
 
== Usage ==
 
== Usage ==
One parameter:
+
Unnamed parameters:
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | ''ID'' }}</code>
+
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | <var>ID</var> }}</code>
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= ''ID'' }}</code>
+
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | <var>ID</var> | <var>NAME</var> }}</code>
  
Two parameters:
+
Named parameters:
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | ''ID'' | ''NAME'' }}</code>
+
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= <var>ID</var> }}</code>
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= ''ID'' | name= ''NAME'' }}</code>
+
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= <var>ID</var> | name= <var>NAME</var> }}</code>
 +
 
 +
Using [[Wikidata]] property {{Property|P1220}}:
 +
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}}<nowiki>}}</nowiki></code>
 +
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | name= <var>NAME</var> <nowiki>}}</nowiki></code>
  
 
== Instructions ==
 
== Instructions ==
Line 28: Line 32:
  
 
== Examples ==
 
== Examples ==
Searching for "Jerry Orbach", you'll reach this page:
 
: <code><nowiki>https://</nowiki>www.ibdb.com/broadway-cast-staff/jerry-orbach-{{hilite|55157}}</code>
 
  
One parameter:
+
=== Unnamed parameters ===
# <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | 55157 }}</code>
+
''URLs:''
#: {{{{BASEPAGENAME}} | 55157 }}
+
: <kbd><nowiki>https://www.ibdb.com/broadway-cast-staff/arthur-miller-</nowiki>{{hilite|4316}}</kbd>
# <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= 55157 }}</code>
+
: <kbd><nowiki>https://www.ibdb.com/broadway-cast-staff/</nowiki>{{hilite|4316}}</kbd>
#: {{{{BASEPAGENAME}} | id= 55157 }}
+
: <kbd><nowiki>https://www.ibdb.com/person.php?id=</nowiki>{{hilite|4316}}</kbd>
 +
 
 +
''Usage:''
 +
: <code><nowiki>* {{</nowiki>{{BASEPAGENAME}} | 4316 | Arthur Miller <nowiki>}}</nowiki></code>
 +
 
 +
''Output:''
 +
:* {{{{BASEPAGENAME}} | 4316 | Arthur Miller }}
 +
 
 +
=== Named parameters ===
 +
''URLs:''
 +
: <kbd><nowiki>https://www.ibdb.com/broadway-cast-staff/jerry-orbach-</nowiki>{{hilite|55157}}</kbd>
 +
: <kbd><nowiki>https://www.ibdb.com/broadway-cast-staff/</nowiki>{{hilite|55157}}</kbd>
 +
: <kbd><nowiki>https://www.ibdb.com/person.php?id=</nowiki>{{hilite|55157}}</kbd>
  
Two parameters:
+
''Usage:''
# <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | 55157 | Jerry Orbach }}</code>
+
: <code><nowiki>* {{</nowiki>{{BASEPAGENAME}} | id= 55157 | name= Jerry Orbach <nowiki>}}</nowiki></code>
#: {{{{BASEPAGENAME}} | 55157 | Jerry Orbach }}
 
# <code><nowiki>{{</nowiki>{{BASEPAGENAME}} | id= 55157 | name= Jerry Orbach }}</code>
 
#: {{{{BASEPAGENAME}} | id= 55157 | name= Jerry Orbach }}
 
  
== Template data ==
+
''Output:''
{{TemplateDataHeader}}
+
:* {{{{BASEPAGENAME}} | id= 55157 | name= Jerry Orbach }}
 +
 
 +
=== No ID in template or Wikidata ===
 +
''Usage:''
 +
: <code><nowiki>{{</nowiki>{{BASEPAGENAME}}<nowiki>}}</nowiki></code>
 +
 
 +
''Output:''
 +
: {{ {{BASEPAGENAME}} }}
 +
 
 +
==TemplateData==
 +
{{TemplateData header}}
 
<templatedata>
 
<templatedata>
 
{
 
{
         "description": "This template generates an external link to a page at the Internet Broadway Database.",
+
         "description": "This template displays an external link to a web page at the Internet Broadway Database (IBDB), operated by the The Broadway League. This template should be used exclusively for people. It is intended for use in the external links section of an article.",
"params": {
+
        "params": {
"id": {
+
                "id": {
"label": "ID",
+
                        "label": "ID",
"description": "ID number used in the URL.",
+
                        "aliases" : [ "1" ],
"type": "number",
+
                        "description": "The \"id\" parameter (or unnamed parameter \"1\") may be used to specify the ID portion of the URL. Example: 4316 is the ID in https://www.ibdb.com/broadway-cast-staff/arthur-miller-4316, https://www.ibdb.com/broadway-cast-staff/4316, or https://www.ibdb.com/person.php?id=4316. This parameter is optional if Wikidata property P1220 exists, but required if not.",
"required": true,
+
                        "type": "number",
"aliases": [ "1" ]
+
                        "required": false,
},
+
"default": "Wikidata property P1220"
"name": {
+
                },
"label": "Name",
+
                "name": {
"description": "Name displayed as the link text. If not specified it defaults to the article's {{PAGENAME}}, without disambiguation.",
+
                        "label": "Name",
"type": "string",
+
                        "aliases" : [ "2" ],
 +
                        "description": "The \"name\" parameter (or unnamed parameter \"2\") may be used to specify the person's name, which is displayed in the link text. This parameter is optional; it defaults to the Wikipedia article name, without any disambiguation.",
 +
                        "type": "string",
 
                         "required": false,
 
                         "required": false,
"aliases": [ "2" ]
+
"default": "{{PAGENAMEBASE}}"
}
+
                }
}
+
},
 +
"paramOrder": [
 +
"id",
 +
"name"
 +
]
 
}
 
}
 
</templatedata>
 
</templatedata>

Revision as of 23:52, 1 August 2018

Template:Uses Wikidata Template:Tracks Wikidata

Template:IBDB name displays an external link to a web page at the Internet Broadway Database (IBDB), operated by the The Broadway League. This template should be used exclusively for people. It is intended for use in the external links section of an article.

If you need to link a show, use Template:IBDB show or Template:IBDB title instead.

Usage

Unnamed parameters:

{{IBDB name | ID }}
{{IBDB name | ID | NAME }}

Named parameters:

{{IBDB name | id= ID }}
{{IBDB name | id= ID | name= NAME }}

Using Wikidata property Template:Property:

{{IBDB name}}
{{IBDB name | name= NAME }}

Instructions

  1. Go to IBDB.com and search for a person
  2. Click on the correct link to go to the person's page. Be sure you're getting the correct person.
  3. The page URL should look like
    https://www.ibdb.com/broadway-cast-staff/xxxxx-xxxxx-#####
    where "xxxxx-xxxxx" indicates the person's name and "#####" indicates a number.
  4. Add to the external links section the text:
    * {{IBDB name|id=#####|name=NAME}}
    where "#####" is the number you've copied, and NAME is the person's full formatted name.

Examples

Unnamed parameters

URLs:

https://www.ibdb.com/broadway-cast-staff/arthur-miller-4316
https://www.ibdb.com/broadway-cast-staff/4316
https://www.ibdb.com/person.php?id=4316

Usage:

* {{IBDB name | 4316 | Arthur Miller }}

Output:

Named parameters

URLs:

https://www.ibdb.com/broadway-cast-staff/jerry-orbach-55157
https://www.ibdb.com/broadway-cast-staff/55157
https://www.ibdb.com/person.php?id=55157

Usage:

* {{IBDB name | id= 55157 | name= Jerry Orbach }}

Output:

No ID in template or Wikidata

Usage:

{{IBDB name}}

Output:

Template:PAGENAMEBASE at the Internet Broadway DatabaseScript error: No such module "EditAtWikidata".Template:WikidataCheck

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 IBDB name

This template displays an external link to a web page at the Internet Broadway Database (IBDB), operated by the The Broadway League. This template should be used exclusively for people. 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") may be used to specify the ID portion of the URL. Example: 4316 is the ID in https://www.ibdb.com/broadway-cast-staff/arthur-miller-4316, https://www.ibdb.com/broadway-cast-staff/4316, or https://www.ibdb.com/person.php?id=4316. This parameter is optional if Wikidata property P1220 exists, but required if not.

Default
Wikidata property P1220
Numberoptional
Namename 2

The "name" parameter (or unnamed parameter "2") may be used to specify the person's name, which is displayed in the link text. This parameter is optional; it defaults to the Wikipedia article name, without any disambiguation.

Default
{{PAGENAMEBASE}}
Stringoptional

Tracking categories

See also