Template:Musichead/doc: Difference between revisions
From Pizza Tower Wiki
Content deleted Content added
Created page with "; Description : This template creates a level article header with music player; it's based on older Template:Level header, but instead of Template:Bandcamp it uses Template:SoundcloudPlayer. : Template uses Extension:TemplateStyles, see Template:SCheader/styles.css for styling. ; Syntax : Type: <code><nowiki>{{level header|<1>|<2>|<3>}}</nowiki></code>, and fill the parameters: * <code>1</code> - image file name with f..." |
No edit summary |
||
(4 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
; Description |
; Description |
||
: This template creates a [[level]] article header with music player |
: This template creates a [[level]] article header with music player. It currently supports audio embeds from Bandcamp (with [[Template:BandcampPlayer]]) and SoundCloud (with [[Template:SoundcloudPlayer]]). |
||
: Template uses [[mw:Extension:TemplateStyles|Extension:TemplateStyles]], see [[Template: |
: Template uses [[mw:Extension:TemplateStyles|Extension:TemplateStyles]], see [[Template:Musichead/styles.css]] for styling. |
||
; Syntax |
; Syntax |
||
: The code depends on embeded service: |
|||
: Type: <code><nowiki>{{level header|<1>|<2>|<3>}}</nowiki></code>, and fill the parameters: |
|||
* '''Bandcamp''' |
|||
* <code>1</code> - image file name with file format (<code>.png</code>) |
|||
:<pre>{{musichead|<image filename>|bandcamp|<track ID>|<album ID>}}</pre> |
|||
* <code>2</code> - full URL of (single) track's page on SoundCloud |
|||
:Album ID is an optional parameter, by default template calls for ''[https://ronandecastel.bandcamp.com/album/pizza-tower-soundtrack Pizza Tower Soundtrack]''. |
|||
* '''SoundCloud''' |
|||
:<pre>{{musichead|<image filename>|soundcloud|<full track URL>}}</pre> |
|||
; Usage example |
; Usage example |
||
: Code |
: Code – Bandcamp entry for [[John Gutter]] and SoundCloud entry for [[Secrets of The World]]: |
||
<pre>{{musichead|PTWiki-levelicon1|bandcamp|967400588}} |
|||
<pre>{{SCheader|Levelicon1.png|https://soundcloud.com/peppino-pizza/unearthly-blues}}</pre> |
|||
{{musichead|PTWiki-leveliconsecret|soundcloud|https://soundcloud.com/clascyjitto/pizza-tower-secret-lockin}}</pre> |
|||
:Result: |
:Result: |
||
{{musichead|PTWiki-levelicon1|bandcamp|967400588}} |
|||
{{SCheader|Levelicon1.png|https://soundcloud.com/peppino-pizza/unearthly-blues}} |
|||
{{musichead|PTWiki-leveliconsecret|soundcloud|https://soundcloud.com/clascyjitto/pizza-tower-secret-lockin}} |
|||
<noinclude>[[Category:Template documentation]]</noinclude> |
<noinclude>[[Category:Template documentation]]</noinclude> |
Latest revision as of 21:52, 1 February 2024
- Description
- This template creates a level article header with music player. It currently supports audio embeds from Bandcamp (with Template:BandcampPlayer) and SoundCloud (with Template:SoundcloudPlayer).
- Template uses Extension:TemplateStyles, see Template:Musichead/styles.css for styling.
- Syntax
- The code depends on embeded service:
- Bandcamp
{{musichead|<image filename>|bandcamp|<track ID>|<album ID>}}
- Album ID is an optional parameter, by default template calls for Pizza Tower Soundtrack.
- SoundCloud
{{musichead|<image filename>|soundcloud|<full track URL>}}
- Usage example
- Code – Bandcamp entry for John Gutter and SoundCloud entry for Secrets of The World:
{{musichead|PTWiki-levelicon1|bandcamp|967400588}} {{musichead|PTWiki-leveliconsecret|soundcloud|https://soundcloud.com/clascyjitto/pizza-tower-secret-lockin}}
- Result: