Template:VideoEmbed
{{tl|VideoEmbed}} is used to embed a Youtube or Twitch video.
Usage
{{VideoEmbed |service= Service Provider |url= Full URL or Identifier |dimensions= <Width>x<Height> (Default to 304x171) |alignment= alignment (Default to 'inline') |description= Video title / description |container= container type |urlArgs= extra URL arguments |autoresize= true/false (Default to 'false') |valignment= vertical placement alignments |poster=File:TestFile.png }}
Template parameters
Attribute | Description | Required? | Default |
---|---|---|---|
service=(twitch/twitchvods/twitchclip/youtube)
|
The video service to call. | Required | <nowiki>-</nowiki> |
url]</nowiki> | The raw ID of the video or URL from the player page. | Required | <nowiki>-</nowiki> |
WIDTHxHEIGHT|xHEIGHT]</nowiki>" | Dimensions in pixels to size the embed container. The standard format is width x height where either can be omitted, but the x must proceed height to indicate it as the height.
Examples: |
Optional | 304x171
|
center|right|inline]</nowiki>" | Align the placement of the video either to the left, centered, or to the right. Inline will allow multiple videos to display side by side without forced line breaks. | Optional | inline
|
description="<nowiki>[wikitext]</nowiki>"
|
Display a description under the embed container. For line breaks use
|
Optional | none |
container="<nowiki>[frame]</nowiki>"
|
Specifies the container type to use for the embed.
|
Optional | none |
urlargs=start=32&end=42
|
Allows extra URL arguments to be appended to the generated embed URL. This is useful for obscure options. Works only on Youtube atm. | Optional | none |
autoresize="false"
|
Automatically resize video. Will use all available width of the parent element. | Optional | false
|
middle|bottom|baseline]</nowiki>" | Align the vertical placement of the video either to the top, middle, bottom, or baseline of the parent element. Using this parameter forces the alignment parameter to be inline. | Optional | none |
poster="<nowiki>[File:TestFile.png]</nowiki>"
|
Using a local file as an embed thumbnail | Optional | none |
Examples:
Youtube with description and start time:
{{VideoEmbed|service=youtube|url=https://www.youtube.com/watch?v=NB5mqAJ9Vl0%7Cdescription=Ferrets First Snow|urlArgs=start=10}}
{{VideoEmbed|service=youtube|url=https://www.youtube.com/watch?v=NB5mqAJ9Vl0%7Cdescription=Ferrets First Snow|urlArgs=start=10}}
Twitch with description, using all available space:
{{VideoEmbed|service=twitch|url=https://www.twitch.tv/ferretsoftware%7Cdescription=FerretSoftware Livestream|autoresize="true"}}
{{VideoEmbed|service=twitch|url=https://www.twitch.tv/ferretsoftware%7Cdescription=FerretSoftware Livestream|autoresize="true"}}
Twitch VOD centered:
{{VideoEmbed|service=twitchvod|url=2261479736|alignment=center}}
{{VideoEmbed|service=twitchvod|url=2261479736|alignment=center}}
Twitch Clip:
{{VideoEmbed|service=twitchclip|url=RenownedBlatantKangarooEleGiggle-tiuHBV-4AWQFN-B4}}
{{VideoEmbed|service=twitchclip|url=RenownedBlatantKangarooEleGiggle-tiuHBV-4AWQFN-B4}}
In combination with {{tl|VideoGallery}}:
{{VideoGallery| {{VideoEmbed|service=twitchclip|url=https://www.twitch.tv/ferretsoftware/clip/RenownedBlatantKangarooEleGiggle-tiuHBV-4AWQFN-B4%7Cdescription=Doing a handstand while peeing}} {{VideoEmbed|service=twitchclip|url=https://www.twitch.tv/ferretsoftware/clip/BovineRelatedAlbatrossCopyThis-FSuhy0lyvjg-JTif%7Cdescription=Doing a flip}} {{VideoEmbed|service=twitchclip|url=https://www.twitch.tv/ferretsoftware/clip/JollyHelpfulWeaselPJSugar-_YSvSmPEMkXQBsri%7Cdescription=Making perfect landings}} {{VideoEmbed|service=twitchclip|url=https://www.twitch.tv/ferretsoftware/clip/AdventurousFairGullThisIsSparta-J_GUReOSda-CpLzb%7Cdescription=Henry cruising through the tubes}} }}
{{VideoGallery| {{VideoEmbed|service=twitchclip|url=https://www.twitch.tv/ferretsoftware/clip/RenownedBlatantKangarooEleGiggle-tiuHBV-4AWQFN-B4%7Cdescription=Doing a handstand while peeing}} {{VideoEmbed|service=twitchclip|url=https://www.twitch.tv/ferretsoftware/clip/BovineRelatedAlbatrossCopyThis-FSuhy0lyvjg-JTif%7Cdescription=Doing a flip}} {{VideoEmbed|service=twitchclip|url=https://www.twitch.tv/ferretsoftware/clip/JollyHelpfulWeaselPJSugar-_YSvSmPEMkXQBsri%7Cdescription=Making perfect landings}} {{VideoEmbed|service=twitchclip|url=https://www.twitch.tv/ferretsoftware/clip/AdventurousFairGullThisIsSparta-J_GUReOSda-CpLzb%7Cdescription=Henry cruising through the tubes}} }}
<includeonly></includeonly>{{doc/end}}