Template:Spotify/doc

From Tardis Wiki, the free Doctor Who reference
< Template:Spotify
Revision as of 04:13, 5 June 2017 by SOTO (talk | contribs) (Created page with "The '''{{tlx|spotify}}''' template creates [https://spotify.com Spotify] embeds on articles. Usage is simple. Spotify URLs are typically split into four types: * <tt>artis...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

The {{spotify}} template creates Spotify embeds on articles. Usage is simple. Spotify URLs are typically split into four types:

  • artist
  • album
  • track
  • playlist

Each of these will be following by a long string of gibberish.

Let's consider Jubilee as our primary example here. You can easily extract the information you need from either the URI (spotify:album:2KavEgxLOcjbZq8OqoFiMD) or from a simple URL (https://open.spotify.com/album/2KavEgxLOcjbZq8OqoFiMD).

  • {{spotify|album=2KavEgxLOcjbZq8OqoFiMD}} will generate the Spotify embed seen on the right.

Simple right? The same exact logic applies to the three other URL types we mentioned. By default, {{Spotify}} appears as a small thumbnail-sized object, aligned to the right side of the page.

Spotify embeds can not only have different heights, though, but can also align to the left side instead.

align=left produces such a left-aligned Spotify object.

To achieve a longer (yet thinner) object, with greater control to it, use one of the following height options:
280, 350 or 380.
280 is, of course, preferable, as it takes up less space on the page. Take caution in using these larger Spotify embeds, not to take away too much from space for content. Spotify is not available in quite all countries, and not all users will have an account to listen with on the page directly.