Template:External music video/doc

From Talking Heads Wiki
Jump to navigation Jump to search

Most music videos cannot be uploaded to Wikipedia because of copyright restrictions. However, it is permissible to link to videos if they are hosted on a site that has licensed them for online viewing. Use this template to add a music video link to an infobox created by {{Infobox song}}, {{Infobox album}}, or other appropriate infobox.

Usage

This template is used with the |misc= parameter of the infobox template. It should not be used on its own. If this template is substituted, it will return a cleaned-up copy of itself with unnecessary parameters removed and deprecated parameters replaced. Parameter indentation will also automatically be fixed.

Code

Music video

<syntaxhighlight lang="wikitext" style="overflow:auto;">{{Infobox song ... | misc = {{subst:External music video

| type        = 
| header      = 
| 1           = 

}} </syntaxhighlight>

type
Enter single to produce a khaki header or song for light blue for other Infobox song types, so that the headers will have a consistent color.
header
Enter the text for the header. If not used, the default is Music video. For no header, enter |header=no. For multiple music video links, set the first to |header=Music videos and the succeeding links to |header=no, so only one header for all will be created (see Example 2).
1
Enter the video link, plus the song title in quote marks, followed by the name of the video site (see Example 1). For YouTube links, use {{YouTube}}, instead of [http: ...] (see Example 2).

Examples

<syntaxhighlight lang="wikitext" style="overflow:auto;">{{Infobox song ... | misc = {{subst:External music video

| type        = song
| header      = Music video
| 1           = "Hurt" at CMT.com

}} </syntaxhighlight>

<syntaxhighlight lang="wikitext" style="overflow:auto;">{{Infobox song ... | misc = {{subst:External music video

| type        = single
| header      = Music videos
| 1           = Template:YouTube

}}{{subst:External music video

| type = single
| header = no
| 1 = Template:YouTube
}}

</syntaxhighlight>

<syntaxhighlight lang="wikitext" style="overflow:auto;">{{Infobox album ... | misc =

Music videosTemplate:YouTube Template:YouTube Template:YouTube Template:YouTube

}} </syntaxhighlight>

TemplateData

This is the TemplateData for this template used by TemplateWizard, VisualEditor and other tools. See a monthly parameter usage report for Template:External music video in articles based on its TemplateData.

TemplateData for External music video

<templatedata> { "params": { "1": { "description": "Link to the internet location holding the video", "example": "| 1 = Template:YouTube", "type": "string", "default": "Empty", "required": true }, "header": { "label": "Header", "description": "Header text", "example": "Music video", "type": "string", "default": "Music video", "autovalue": "Music video", "required": true }, "Upper caption": { "autovalue": "", "type": "string", "deprecated": "Use header field" }, "type": { "description": "Type field - Enter the same type specified in the infobox", "example": "type=single", "type": "string", "default": "Empty", "autovalue": "", "required": true }, "Type": { "deprecated": "Use type (lowercase T)", "type": "string" } }, "description": "External music video template", "format": "block" } </templatedata>