Wikia

LyricWiki

WatchlistRandom pageRecent changes

Help:Templates

Talk14
1,735,568pages on
this wiki
Image - HelpBook.png Help - The LyricWiki Documentation
Getting Started Editing Non-English Songs Uploading content Page ranking Reference
Templates, Categories, Index
Additional Help Integration with other projects Policy Getting Involved About us

Contents


General Information

Templates are provided to reduce the amount of repetitive wikitext in pages. Templates are a sort of shorthand, to make creating and editing wiki pages easier. Templates also help to make LyricWiki visually more uniform. Templates are placed within two sets of curly brackets, or braces, {{}} and contain one or more divisions of information.

If the template has more than one division, each division is separated by a vertical line, or pipe |. The first division contains the name of the template, followed by any number of divisions containing information that are used to complete the template. More often, the template uses named parameters to make the order irrelevant and the parameters optional.

This page contains a listing of all frequently used and useful templates available on LyricWiki. If you find a template to be missing, please insert it at the appropriate location in the list. For documentation and use of the template, please refer to the template page.

Templates without much information are usually formatted as:

{{Name|Division Two|Division Three}}

Templates containing more information are usually formatted as:

{{Name
|Division Two 
|Division Three 
|Division Four 
|Named Parameter One = value 
|Named Parameter Two = value 
}}

NOTE: Like all pages on LyricWiki, templates are case-sensitive, except the first letter of the template name. Therefore, {{Wikipedia}} and {{wikipedia}} will produce the same result, but {{WikiPedia}} won't.


Wikipedia

All LyricWiki articles for which a Wikipedia page exists should include a link to that page. The {{ArtistHeader}}, {{Album}} and {{SongFooter}} templates have parameters for producing such a link. Here are some additional options:

Floating Box

A floating box containing the article link and the Wikipedia graphic.

For example, the Wikipedia template:

{{Wikipedia|Country (film)|Country}}

produces:

Wikipedia
Wikipedia has an article on

In this example, the first division holds the template's name (in this case, Wikipedia), followed by two divisions that specify information for completing the template. The second division specifies the name of the Wikipedia article being linked to. In this case, "Country" wouldn't be specific enough to link to the film's article, so "Country (film)" must be used. The final division specifies the title that LyricWiki users will see, i.e. "Country".

See the template documentation for more information.

NOTE:

Simple Text

A simple text link to a Wikipedia page can be created using the {{wp}} template:

{{wp|Article name|display text}}

All parameters of the {{wp}} are the same as for the {{Wikipedia}} template. For example, this text...

Read about {{wp|Country (film)|Country}} on Wikipedia.

...produces the following result:

Read about Country on Wikipedia.

Simple Text with Icon

The template {{wpi}} is similar to the simple text link above but is preceded by a Wikipedia icon:

Read about {{wpi|Country (film)|Country}} on Wikipedia.

...produces the following result:

Read about Wikipedia Country on Wikipedia.

Song Flagging

Multiple Languages

In the case that a song is released in more than one language, it is recommended that links to the other versions of the lyrics be added. The {{MultipleLanguages}} template makes this task easier.

{{MultipleLanguages
|English Song Title/en
|Spanish Song Title/es
|...
}}

See David Bowie:"Heroes" for a working example.

Common language codes are:

  • de (German)
  • en (English)
  • es (Spanish)
  • fr (French)
  • ja (Japanese)
  • ko (Korean)
  • pl (Polish)
  • ru (Russian)
  • zh (Chinese)

A complete Wikipedia list of ISO 639-1 language codes can be found here.

Instrumental Tracks

Tracks that are instrumentals should be marked with the {{Instrumental}} template inside the lyric tags:

<lyrics>{{Instrumental}}</lyrics>

This template only has one division, its name. It produces the following:

Informational templates

  • Information about the song: {{SInfo}}
  • General information box: {{Info}}
  • Instrumental song: {{Instrumental}}
  • Cover version of a song:
    • {{Cover}} for a link to the original song
    • {{Cover2}} for a link to the cover version
    • {{Covered}} for a collapsible list of artists who have covered the song
  • Additional albums song released on: {{AddAlb}}
  • Parody of another song: {{Parody}}
  • Unplugged (Acoustic) album: {{Unplugged}}
  • Remix of original song: {{Remix}}
  • {{GameFeature}}
  • {{Live Lyrics}}
  • {{No.1}}

Awards

  • (Grammy) award: {{Award}} (or specifically: {{Grammy}}).
  • Album Of The Week: {{AOTW}}
  • Song Of The Day: {{SOTD}}

Flagging for Edits

  • General request for editing: {{Edit}}
  • When possible, please use one of the following instead:

Artist Pages

See Help:Contents/Editing/Formatting/Artists for more information.

  • To display an album picture next to a track listing insert the {{Album Art}} template directly under the album's title:
{{Album Art|IMAGE|ALBUM NAME}}

IMAGE is generally in the form ARTIST - ALBUM NAME.jpg

  • When {{Album Art}} invades into an album listing below it, use {{Clear}} after that album listing to prevent the invasion. {{Clear}} inserts a division break.
  • {{ft}} for listing featured artists
  • {{H4}} for formatting headers for individual discs
  • {{Labels}}
  • {{tl|Genres))

Multiple languages

User (talk) pages

  • Welcome to LyricWiki message: {{Welcome}}
  • Welcome to LyricWiki and invitation to register for unregistered users: {{WelcomeIP}}
  • Reverted edit: {{Reverted}} (for inappropriate but good-faith edits)
  • Vandalism warning: {{WarnUser}} or {{WarnUser/Editing}} (for users who are clearly committing vandalism)
  • {{ArchNav}}: for archive talk pages

User pages

Wiki restrictions

External linking

Administration

Contents

A template is a special type of page that has been designed so its content can be included in other pages. Since a given template can be included in many pages, templates can help reduce duplication and promote a uniform style between pages.

Templates are usually located in the Template namespace. This includes any page with a name beginning with Template:, such as Template:Name.

Video OverviewEdit

If you're new to templates, this video will help you get started... Introduction to Templates

Why use templates?Edit

Templates can be useful for...

  • Creating content that should appear on many pages.
  • Formatting content (like infoboxes) in a way that should be consistent across many pages.
  • Creating a shortcut for writing things that you repeat often when communicating with others.
  • Replacing long, complicated code so that a page is easier for other users to edit.
  • Protecting parts of a page from editing while leaving other sections open for edits.

How to Create a Basic TemplateEdit

Templates can be very powerful, but also sometimes very complicated. It often helps to start by creating the simplest possible kind of template, and then experimenting from there.

  • Type "Hello World" in the editor.
  • Click "Publish." You have just created a template with some sample content.
  • On your wiki, create a new article called "Testing Templates".
  • In the editor, to Source mode and enter the following code:
{{Example}}
  • Click Publish. Your "Testing Templates" page should display the text you added to your template.

You've successfully created and used a template! Now you can change the content of your template and add it to more pages to make it more useful for your wiki.

How to Add and Edit Pre-Existing TemplatesEdit

Templates-rightrail.png

Wikis come with pre-loaded with a many default templates. Here's how to use them.

  • View a complete list of templates available on your wiki by going to Special:AllPages and selecting "Template" from the namespace dropdown menu. Click "Go" and all available templates will appear in a list.
  • In another tab, open an article page for editing in Visual Mode.
  • In the "Templates" section of the right rail, click "Add other templates".
  • Search for the name of the template you would like to use (referencing the list you found above).
  • If any content is needed for the template, enter it in the Parameters section. Preview the template to make sure it looks right.
  • Click "Okay". The template appears on the page as a green puzzle piece, to mark its placement.
  • Mouse over the puzzle piece to view the template. This will also give you options to edit and delete it.
  • Publish the page when you're ready.

Substituting templatesEdit

A different way to use a template is to substitute its content into a page. This is done by inserting subst: immediately after the opening braces: {{subst:templatename}}. Once the page is saved, the link to the template is removed and the template output is substituted in its place and can be further edited. Any updates to the template will not affect the content that was substituted into the page.

Creating an advanced templateEdit

View this instructional video for more guidance.


To learn how to change the output of the template based on what the user inputs, see Help:Template parameters and Help:Parser functions.

Updating and adding standard templatesEdit

Wikia's Starter Pages and Templates wikis occasionally improve some of their documentation as well as adding new templates specifically designed for Wikia sites, and are therefore worth checking from time to time. For sites created before about December 2008, the Starter Pages wiki should be compared and ideally used for upgrading to its standard documentation system similar to that introduced in Wikipedia.

See alsoEdit

Further Help & FeedbackEdit

Latest Photos

Add a Photo
90,116photos on this wiki
See more >

Recent Wiki Activity

See more >

Around Wikia's network

Random Wiki