VideoTutorial: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
(Basic template for video tutorials.)
 
(Simplify template since embeds don't work.)
Line 4: Line 4:


==Example Output==
==Example Output==
<iframe width="560" height="315" src="https://www.youtube.com/embed/9rVo2Yj-xcw" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
{{VideoTutorial
|https://www.youtube.com/watch?v=9rVo2Yj-xcw
|title=Tom Chapman's MapTool Tutorial
|caption=The first video in the series.
}}


==Example==
==Example==
<pre>{{VideoTutorial
<pre>{{VideoTutorial
|https://www.youtube.com/watch?v=9rVo2Yj-xcw
|title=Tom Chapman's MapTool Tutorial
|title=Tom Chapman's MapTool Tutorial
|URL=https://www.youtube.com/watch?v=9rVo2Yj-xcw
|embed=<iframe width="560" height="315" src="https://www.youtube.com/embed/9rVo2Yj-xcw" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
|caption=The first video in the series.
|caption=The first video in the series.
</pre>
}}</pre>


=Source=
=Source=
Edit this section to view template source.
Edit this section to view template source.
</noinclude><includeonly><div class="video_tutorial">
</noinclude><includeonly><div style="float:right; padding:.5rem; border: 1px solid grey; background: #fafafa" class="video_tutorial">
{{#if: {{{title|}}} | {{{title}}} |}}
<a href="{{{1}}}" target="_blank"><strong>{{#if: {{{2|}}} | {{{2}}} | Video Tutorial}}</strong></a>
{{{embed}}}
{{#if: {{{3|}}} | <br><em>{{{3}}}</em> |}}
{{#if: {{{caption|}}} | {{{caption}}} |}}
</div>
</div>
[[Category:Pages with Video Tutorials]]</includeonly>
[[Category:Pages with Video Tutorials]]</includeonly>
<noinclude>[[Category:Templates]]</noinclude>
<noinclude>[[Category:Templates]]</noinclude>

Revision as of 05:19, 26 June 2021

Template Usage

This template wraps video embed code intended for demonstration and tutorial videos.

Example Output

Example

{{VideoTutorial
|https://www.youtube.com/watch?v=9rVo2Yj-xcw
|title=Tom Chapman's MapTool Tutorial
|caption=The first video in the series.
}}

Source

Edit this section to view template source.