Difference between revisions of "Template:YouTubeVideo"
Jump to navigation
Jump to search
(Add align parameter) |
(fix margins) |
||
Line 10: | Line 10: | ||
|{{t|height}}= Optional. video height - whole number only - ie no 'px' (default 300)<br/> | |{{t|height}}= Optional. video height - whole number only - ie no 'px' (default 300)<br/> | ||
<nowiki>}}</nowiki> | <nowiki>}}</nowiki> | ||
− | </noinclude><includeonly>{| class="wikitable" width="20%" style="float:{{#ifeq:{{{align}}}|left|left|right}}; margin: 1.0em | + | </noinclude><includeonly>{| class="wikitable" width="20%" style="float:{{#ifeq:{{{align}}}|left|left|right}}; margin: 1.0em 1.0em 1.0em 1.0em;" |
|- | |- | ||
|{{#widget:YouTube|{{#if:{{{width|}}}|width={{{width|}}}px}}|{{#if:{{{height|}}}|height={{{height|}}}px}}|id={{{code|}}}}} | |{{#widget:YouTube|{{#if:{{{width|}}}|width={{{width|}}}px}}|{{#if:{{{height|}}}|height={{{height|}}}px}}|id={{{code|}}}}} |
Latest revision as of 11:34, 12 June 2019
This template is for placing a YouTube video and caption in a right-floating box.
The caption text will wrap within the box border and the borders will expand to accommodate whatever width & height are specified for the video
Usage:
{{YouTubeVideo
|code= Mandatory. YouTube video code
|align= Optional. {left,right} - defaults to "right"
|caption= Optional. video caption - standard wikitext including links
|width= Optional. video width - whole number only - ie no 'px' (default 360)
|height= Optional. video height - whole number only - ie no 'px' (default 300)
}}