Template:Infobox album: Difference between revisions

From SPCodex, The Smashing Pumpkins wiki
No edit summary
No edit summary
 
(65 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{Infobox
<noinclude>{{#cargo_declare:_table=albums
| name = String(mandatory=1)
| cover = File
| type = List (,) of String (mandatory=1;allowed values=ep,studio,demo,live,compilation,box set,video,tribute,bootleg,promotional)
| artist = Page (mandatory=1;allowed values=The Smashing Pumpkins,Billy Corgan,James Iha,Jimmy Chamberlin Complex,Zwan,Various artists)
| studio = List (,) of String
| producer = List (,) of Page
| engineer = List (,) of Page
| released = Date
| discogs = Integer
| musicbrainz = String
}}</noinclude><includeonly>{{#cargo_store:_table=albums
| name = {{{name|{{PAGENAME}}}}}
| cover = {{#if:{{{image|{{{cover|}}}}}}|{{{image|{{{cover|}}}}}}|{{album image|{{{name|{{PAGENAME}}}}}}}}}
| type = {{lc:{{{type|{{{Type|}}}}}}}}
| artist = {{#invoke:String2|ucfirst|{{delink|{{{artist|}}}}}}}
| studio = {{#invoke:String2|ucfirst|{{delink|{{{studio|}}}}}}}
| producer = {{#invoke:String2|ucfirst|{{delink|{{{producer|}}}}}}}
| engineer = {{#invoke:String2|ucfirst|{{delink|{{{engineer|}}}}}}}
| released = {{{released_cargo|{{{released|}}}}}}
| discogs = {{{discogs|}}}
| musicbrainz = {{{musicbrainz|}}}
}}{{#invoke:Infobox album|categories|{{lc:{{{type|{{{Type|}}}}}}}}|{{#invoke:String2|ucfirst|{{delink|{{{artist|}}}}}}}}}</includeonly>{{Infobox
| italic title= {{{italic_title|<noinclude>no</noinclude>}}}
| italic title= {{{italic_title|<noinclude>no</noinclude>}}}
| bodyclass  = vevent haudio
| bodyclass  = vevent haudio


| aboveclass  = summary album
| aboveclass  = summary album
| abovestyle  = font-style: italic; background-color: {{#ifeq:{{Infobox album/color|{{{type|}}}}}|khaki|{{Infobox album/color}}|{{Infobox album/color|{{{type|}}} }} }}
| abovestyle  = font-style: italic; background-color:{{Infobox album/color|{{{type|}}}}}
| above      = {{#if:{{{name|}}}|{{{name}}}|<includeonly><span style="font-style: normal">Untitled</span></includeonly>}}
| above      = {{#if:{{{name|}}}|{{{name}}}|<includeonly><span style="font-style: normal">Untitled</span></includeonly>}}


| image      = {{#invoke:InfoboxImage|InfoboxImage|image={{#switch:{{{image|{{{cover|}}}}}}|blank=|???=Nocover.png|#default={{#if:{{{image|{{{cover|}}}}}}|{{{image|{{{cover|}}}}}}|{{album image|{{{name|{{BASENAME}}}}}}}|border={{{border|}}}|alt={{{alt|}}}}}
| image      = {{#invoke:InfoboxImage|InfoboxImage|image={{#switch:{{{image|{{{cover|}}}}}}|blank=|???=Nocover.png|#default={{{image|{{{cover|{{album image|{{{name|{{PAGENAME}}}}}}}}}}}}}|border={{{border|}}}|alt={{{alt|}}}}}}}
| caption    = {{{caption|}}}
| caption    = {{{caption|}}}


| headerstyle = background-color: {{#ifeq:{{Infobox album/color|{{{type|}}}}}|khaki|{{Infobox album/color}}|{{Infobox album/color|{{{type|}}}}}}}
| headerstyle = background-color:{{Infobox album/color|{{{type|}}}}}
| headerclass = description
| headerclass = description


| header1    = <includeonly>{{Infobox album/link|{{{type|}}} }}</includeonly>{{#if:{{{longtype|}}}|&#32;{{{longtype|}}}}}{{#if:{{{artist|}}}|&#32;by <div class="contributor" style="display:inline">{{{artist|}}}</div> }}
| header1    = <includeonly>{{Infobox album/link|{{{type|}}} }}</includeonly>{{#if:{{{longtype|}}}|&#32;{{{longtype|}}}}}{{#if:{{{artist|}}}|&#32;{{#if:{{#pos:{{{type|}}}|bootleg}}|of|by}} <div class="contributor" style="display:inline">{{#ifexist:{{delink|{{{artist|}}}}}|[[{{delink|{{{artist}}}}}]]|{{{artist|}}}}}</div> }}
| label2      = Released
| label2      = Released
| data2      = {{{released|}}}
| data2      = {{{released|}}}{{#if:{{{released_ref|}}}|{{{released_ref}}}}}
| class2      = published
| class2      = published
| label3      = Recorded
| label3      = {{#if:{{{recorded|}}}|Recorded|[[Studio sessions]]}}
| data3      = {{{recorded|}}}
| data3      = {{#if:{{{recorded|}}}|{{{recorded|}}}{{#if:{{{recorded_ref|}}}|{{{recorded_ref}}}}}|<includeonly>{{#invoke:infobox_album|studio_sessions|{{{name|{{PAGENAME}}}}}}}</includeonly>}}
| class3      = plainlist
| class3      = plainlist
| label4      = Venue
| label4      = Venue
| data4      = {{{venue|}}}
| data4      = {{{venue|}}}
| label5      = [[:Category:Albums by studio|Studio]]
| label5      = [[:Category:Albums by studio|Studio]]
| data5      = {{{studio|}}}
| data5      = {{#if:{{{studio|}}}|{{#invoke:link|studio|{{{studio}}}}}}}
| class5      = plainlist
| class5      = plainlist
| label6      = Genre
| label6      = Genre
Line 42: Line 64:
| data11      = {{#invoke:Link|producer|{{delink|{{{producer|}}}}}|{{{name|{{PAGENAME}}}}}|Album}}
| data11      = {{#invoke:Link|producer|{{delink|{{{producer|}}}}}|{{{name|{{PAGENAME}}}}}|Album}}
| class11    = hlist
| class11    = hlist
| label12    = Compiler
| label12    = Format
| data12      = {{{compiler|}}}
| data12      = {{{format|}}}
| class12    = hlist
| class12    = hlist
 
| header13    = {{#ifeq:{{#invoke:Chronology|check|{{delink|{{{artist|}}}}}|albums|{{delink|{{{name|{{PAGENAME}}}}}}}}}|true|{{#ifexist:{{delink|{{{artist|}}}}}|[[{{#invoke:String2 | ucfirst |{{delink|{{{artist|}}}}}}}]] chronology}}}}
| header13    = {{#if:{{{last_album|}}}{{{next_album|}}}{{{prev_title|}}}{{{next_title|}}}|{{#if:{{{chronology|}}}|{{{chronology|}}}|{{#invoke:String2 | ucfirst |{{{artist|}}}}}}} chronology}}
| data14      = <includeonly>{{#invoke:Chronology|main|{{delink|{{{artist|}}}}}|albums|{{delink|{{{name|{{PAGENAME}}}}}}}}}</includeonly>
| data14      = {{#if:{{{last_album|}}}{{{next_album|}}}{{{prev_title|}}}{{{next_title|}}}|
{{(!}} style="background: transparent; width: 100%; min-width: 100%; border-collapse: collapse"
{{!}}- style="line-height: 1.4em;"
{{!}} style="width: 33%; text-align: center; vertical-align: top; padding: .2em .1em .2em 0" {{!}} {{#if:{{{prev_title|}}}|''{{{prev_title}}}''{{#if:{{{prev_year|}}}|<br />({{{prev_year}}})}}|{{{last_album|}}}<span style="display:none">{{#if:{{{last_album|}}}|{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{last_album|}}}|2=^''([^<]+)''%s*< ?/? ?[Bb][Rr] ?/? ?>|nomatch={{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{last_album|}}}|2=^<div class="plainlist"><ul><li>''([^<]+)''</li>}}}}{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{last_album|}}}|2=< ?/? ?[Bb][Rr] ?/? ?>%s*%((%d+)%)|nomatch={{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{last_album|}}}|2=<li>%((%d+)%)</li></ul></div>}}}}}}</span> }}
{{!}} style="width: 33%; text-align: center; vertical-align: top; padding: .2em .1em" {{!}} {{{this_album|'''''{{{name|{{PAGENAMEBASE}}}}}'''''}}}{{#if:{{{next_year|}}}{{{prev_year|}}}|<br />({{{year|{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|{{{released|}}}|%d%d%d+}}}}})}}
{{!}} style="width: 33%; text-align: center; vertical-align: top; padding: .2em 0 .2em .1em" {{!}} {{#if:{{{next_title|}}}|''{{{next_title}}}''{{#if:{{{next_year|}}}|<br />({{{next_year}}})}}|{{{next_album|}}}<span style="display:none">{{#if:{{{next_album|}}}|{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{next_album|}}}|2=^''([^<]+)''%s*< ?/? ?[Bb][Rr] ?/? ?>|nomatch={{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{next_album|}}}|2=^<div class="plainlist"><ul><li>''([^<]+)''</li>}}}}{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{next_album|}}}|2=< ?/? ?[Bb][Rr] ?/? ?>%s*%((%d+)%)|nomatch={{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{next_album|}}}|2=<li>%((%d+)%)</li></ul></div>}}}}}}</span> }}
{{!)}}
}}
| below      = {{{misc|}}}
| below      = {{{misc|}}}
}}<includeonly>{{#ifeq:{{{type|}}}|EP|[[Category:EPs]]{{#if:{{{artist|}}}|[[Category:{{delink|{{{artist}}}}} EPs]]}}|[[Category:Albums]]{{#if:{{{artist|}}}|[[Category:{{delink|{{{artist}}}}} albums]]}}{{#if:{{{type|}}}|[[Category:{{{type}}} albums]]}}}}</includeonly>{{#if:{{#ifeq:{{str left|{{{last_album|}}}|22}}|<div class="plainlist"|1|}}{{#ifeq:{{str left|{{{this_album|}}}|22}}|<div class="plainlist"|1|}}{{#ifeq:{{str left|{{{next_album|}}}|22}}|<div class="plainlist"|1|}}|[[Category:Pages using infobox chronology parameters with plainlists]]}}{{#ifeq:{{{type|}}}||[[Category:Pages using infobox album with empty type parameter]]}}{{#invoke:Check for unknown parameters|check|unknown={{main other|[[Category:Pages using infobox album with unknown parameters|_VALUE_{{PAGENAME}}]]}}|preview=Page using [[Template:Infobox album]] with unknown parameter "_VALUE_"|ignoreblank=y|italic_title |type |name |image |cover |border |alt |caption |longtype |artist |released |recorded |venue |studio |genre |length |language |label |director |producer |compiler |prev_title|prev_year|next_title|next_year|chronology|year|misc}}{{#if:{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{prev_title|}}}{{{last_album|}}}{{{prev_year|}}}{{{next_title|}}}{{{next_album|}}}{{{next_year|}}}{{{italic_title|}}}{{{italic title|}}}{{{type|}}}{{{name|}}}{{{image|}}}{{{cover|}}}{{{border|}}}{{{alt|}}}{{{caption|}}}{{{longtype|}}}{{{artist|}}}{{{released|}}}{{{recorded|}}}{{{venue|}}}{{{studio|}}}{{{genre|}}}{{{length|}}}{{{language|}}}{{{label|}}}{{{director|}}}{{{producer|}}}{{{compiler|}}}{{{chronology|}}}{{{this_album|}}}{{{year|}}}x|2=</?t[drh][ >]|nomatch=}}|{{main other|[[Category:Music infoboxes with malformed table placement|A]]}}}}{{main other|{{#if:{{{length|}}}|{{#if:{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{#invoke:hms|main|duration={{{length|}}}}}|2=class="duration"|plain=true|nomatch=}}|[[Category:Articles with hAudio microformats]]}}}}}}<noinclude>
}}{{#ifeq:{{{type|}}}||[[Category:Pages using infobox album with empty type parameter]]}}{{#invoke:Check for unknown parameters|check|unknown={{main other|[[Category:Pages using infobox album with unknown parameters|_VALUE_{{PAGENAME}}]]}}|preview=Page using [[Template:Infobox album]] with unknown parameter "_VALUE_"|ignoreblank=y|italic_title |type |name |image |cover |border |alt |caption |longtype |artist |released|released_cargo |released_ref |recorded |recorded_ref |venue |studio |genre |length |language |label |director |producer |format |year|misc|discogs|musicbrainz}}{{#if:{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{{italic_title|}}}{{{italic title|}}}{{{type|}}}{{{name|}}}{{{image|}}}{{{cover|}}}{{{border|}}}{{{alt|}}}{{{caption|}}}{{{longtype|}}}{{{artist|}}}{{{released|}}}{{{recorded|}}}{{{venue|}}}{{{studio|}}}{{{genre|}}}{{{length|}}}{{{language|}}}{{{label|}}}{{{director|}}}{{{producer|}}}{{{format|}}}{{{year|}}}x|2=</?t[drh][ >]|nomatch=}}|{{main other|[[Category:Music infoboxes with malformed table placement|A]]}}}}{{main other|{{#if:{{{length|}}}|{{#if:{{#invoke:String|match|error_category=Music infoboxes with Module:String errors{{!}}A|1={{#invoke:hms|main|duration={{{length|}}}}}|2=class="duration"|plain=true|nomatch=}}|[[Category:Articles with hAudio microformats]]}}}}}}<noinclude>
{{Documentation}}
{{Documentation}}
<!-- Add categories to the /doc subpage, not here. -->
<!-- Add categories to the /doc subpage, not here. --><templatedata>
{
"params": {
"italic_title": {},
"type": {
"label": "Type",
"description": "Comma-separated list containing any of: ep, studio, demo, live, compilation, box set, video, tribute, bootleg, promotional",
"type": "string",
"suggested": true
},
"name": {
"label": "Name",
"description": "Title of the album. This must be exactly the same as the title of the article for the album.",
"type": "string",
"required": true
},
"alt": {},
"caption": {
"description": "Caption shown under the image"
},
"artist": {
"label": "Artist",
"description": "Artist who made the album",
"example": "The Smashing Pumpkins",
"type": "string",
"required": true
},
"released": {
"label": "Released",
"description": "The date when the album was released",
"example": "November 15, 2019",
"type": "date",
"suggested": true
},
"recorded": {
"label": "Recorded",
"description": "Date(s) when the album was recorded",
"example": "December 1990 – March 1991",
"type": "string",
"suggested": true
},
"venue": {},
"studio": {
"label": "Studio",
"description": "Studio(s) where the album was recorded. Known studios are automatically linked",
"example": "Chicago Recording Company",
"type": "string",
"suggested": true
},
"genre": {},
"length": {
"label": "Length",
"description": "Total duration of the album",
"example": "45:15",
"type": "string",
"suggested": true
},
"label": {
"label": "Record label",
"description": "Record label(s) that released the album",
"example": "Caroline, Hut",
"type": "string",
"suggested": true
},
"director": {},
"producer": {
"label": "Producer(s)",
"description": "Producers of the album. Names are automatically linked",
"example": "Butch Vig, Billy Corgan",
"type": "string",
"suggested": true
},
"format": {
"label": "Format",
"description": "Medium that the album was released on",
"example": "Cassette, CD",
"type": "string"
},
"year": {},
"misc": {}
},
"description": "Adds an infobox for an album. Some things like the chronology are automatically generated.",
"format": "{{_\n| _ = _\n}}\n"
}
</templatedata>
</noinclude>
</noinclude>

Latest revision as of 03:34, 8 December 2023

This template defines the table "albums". View table.

Template documentation[create]

Adds an infobox for an album. Some things like the chronology are automatically generated.

[Edit template data]

Template parameters

This template has custom formatting.

ParameterDescriptionTypeStatus
italic_titleitalic_title

no description

Unknownoptional
Typetype

Comma-separated list containing any of: ep, studio, demo, live, compilation, box set, video, tribute, bootleg, promotional

Stringsuggested
Namename

Title of the album. This must be exactly the same as the title of the article for the album.

Stringrequired
altalt

no description

Unknownoptional
captioncaption

Caption shown under the image

Unknownoptional
Artistartist

Artist who made the album

Example
The Smashing Pumpkins
Stringrequired
Releasedreleased

The date when the album was released

Example
November 15, 2019
Datesuggested
Recordedrecorded

Date(s) when the album was recorded

Example
December 1990 – March 1991
Stringsuggested
venuevenue

no description

Unknownoptional
Studiostudio

Studio(s) where the album was recorded. Known studios are automatically linked

Example
Chicago Recording Company
Stringsuggested
genregenre

no description

Unknownoptional
Lengthlength

Total duration of the album

Example
45:15
Stringsuggested
Record labellabel

Record label(s) that released the album

Example
Caroline, Hut
Stringsuggested
directordirector

no description

Unknownoptional
Producer(s)producer

Producers of the album. Names are automatically linked

Example
Butch Vig, Billy Corgan
Stringsuggested
Formatformat

Medium that the album was released on

Example
Cassette, CD
Stringoptional
yearyear

no description

Unknownoptional
miscmisc

no description

Unknownoptional