Template:Youtube/doc: Difference between revisions
(New Page: "This template embeds 1 or 2 YouTube videos into a page. Note that you can also use {{template|YoutubeAudio}} to hide the video and use YouTube as an audio player. ;Parameters <pre> ...") |
No edit summary |
||
(2 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
This template embeds 1 | This template embeds 1~5 YouTube videos into a page. | ||
Note that you can also use {{template|YoutubeAudio}} to hide the video and use YouTube as an audio player. | Note that you can also use {{template|YoutubeAudio}} to hide the video and use YouTube as an audio player. | ||
;Parameters | ; Parameters | ||
<pre> | <pre> | ||
{{youtube | {{youtube | ||
|video1 = First YouTube video ID | | video1 = First YouTube video ID | ||
|title1 = Video title (optional) | | title1 = Video title (optional) | ||
|width1 = Width of video (optional, default 500 pixels) | | width1 = Width of video (optional, default 500 pixels) | ||
|video2 = Second YouTube video ID | | video2 = Second YouTube video ID | ||
|title2 = Video title (optional) | | title2 = Video title (optional) | ||
|width2 = Width of video (optional, default 500 pixels) | | width2 = Width of video (optional, default 500 pixels) | ||
| video3 = Third YouTube video ID | |||
| title3 = Video title (optional) | |||
| width3 = Width of video (optional, default 500 pixels) | |||
| video4 = Fourth YouTube video ID | |||
| title4 = Video title (optional) | |||
| width4 = Width of video (optional, default 500 pixels) | |||
| video5 = Fifth YouTube video ID | |||
| title5 = Video title (optional) | |||
| width5 = Width of video (optional, default 500 pixels) | |||
}} | }} | ||
</pre> | </pre> | ||
;Example | ; Example 1 | ||
<pre> | <pre> | ||
{{youtube|video1=MpmDawqOfqs|title1=GTA Vice City trailer}} | {{youtube | ||
| video1 = MpmDawqOfqs | |||
| title1 = GTA Vice City trailer | |||
}} | |||
</pre> | |||
{{youtube | |||
| video1 = MpmDawqOfqs | |||
| title1 = GTA Vice City trailer | |||
}} | |||
; Example 2 | |||
<pre> | |||
{{youtube | |||
| video1 = nFKjLYjw7qc | |||
| title1 = GTA Vice City Pedestrians rioting<br />with weapons | |||
| width1 = 400 | |||
| video2 = GiSTbq-u37Y | |||
| title2 = Vice City Riots | |||
| width2 = 400 | |||
| video3 = m47D6ETyqvo | |||
| title3 = Vice City:Pedestrians rioting | |||
| width3 = 400 | |||
}} | |||
</pre> | </pre> | ||
{{youtube|video1= | {{youtube | ||
| video1 = nFKjLYjw7qc | |||
| title1 = GTA Vice City Pedestrians rioting<br />with weapons | |||
| width1 = 400 | |||
| video2 = GiSTbq-u37Y | |||
| title2 = Vice City Riots | |||
| width2 = 400 | |||
| video3 = m47D6ETyqvo | |||
| title3 = Vice City:Pedestrians rioting | |||
| width3 = 400 | |||
}} |
Latest revision as of 20:54, 11 July 2015
This template embeds 1~5 YouTube videos into a page.
Note that you can also use {{YoutubeAudio}} to hide the video and use YouTube as an audio player.
- Parameters
{{youtube | video1 = First YouTube video ID | title1 = Video title (optional) | width1 = Width of video (optional, default 500 pixels) | video2 = Second YouTube video ID | title2 = Video title (optional) | width2 = Width of video (optional, default 500 pixels) | video3 = Third YouTube video ID | title3 = Video title (optional) | width3 = Width of video (optional, default 500 pixels) | video4 = Fourth YouTube video ID | title4 = Video title (optional) | width4 = Width of video (optional, default 500 pixels) | video5 = Fifth YouTube video ID | title5 = Video title (optional) | width5 = Width of video (optional, default 500 pixels) }}
- Example 1
{{youtube | video1 = MpmDawqOfqs | title1 = GTA Vice City trailer }}
GTA Vice City trailer |
---|
{{#ev:youtube|MpmDawqOfqs|500}} |
- Example 2
{{youtube | video1 = nFKjLYjw7qc | title1 = GTA Vice City Pedestrians rioting<br />with weapons | width1 = 400 | video2 = GiSTbq-u37Y | title2 = Vice City Riots | width2 = 400 | video3 = m47D6ETyqvo | title3 = Vice City:Pedestrians rioting | width3 = 400 }}
GTA Vice City Pedestrians rioting with weapons |
Vice City Riots | Vice City:Pedestrians rioting |
---|---|---|
{{#ev:youtube|nFKjLYjw7qc|400}} | {{#ev:youtube|GiSTbq-u37Y|400}} | {{#ev:youtube|m47D6ETyqvo|400}} |