Template:YouTube: Difference between revisions
No edit summary |
No edit summary |
||
| Line 3: | Line 3: | ||
{{#widget:YouTube|id={{{1}}}|width={{#switch:{{{2}}}|small=356|medium=560|big=640|large=854|100%}}}} | {{#widget:YouTube|id={{{1}}}|width={{#switch:{{{2}}}|small=356|medium=560|big=640|large=854|100%}}}} | ||
<!-- mandatory properties for google rich snippets --> | <!-- mandatory properties for google rich snippets --> | ||
<meta itemprop="name" content="{{#ask: [[Category:YouTube videos]] [[YouTube video ID:: | <meta itemprop="name" content="{{#ask: [[Category:YouTube videos]] [[YouTube video ID::{{{1}}}]] |link=none |default={{#external_value:title}} }}"/> | ||
<meta itemprop="description" content="{{#ask: [[Category:YouTube videos]] [[YouTube video ID:: | <meta itemprop="description" content="{{#ask: [[Category:YouTube videos]] [[YouTube video ID::{{{1}}}]] |link=none |default={{#external_value:title}} }}" /> | ||
<meta itemprop="thumbnailUrl" content="https://i.ytimg.com/vi/ | <meta itemprop="thumbnailUrl" content="https://i.ytimg.com/vi/{{{1}}}/maxresdefault.jpg" /> | ||
<meta itemprop="uploadDate" content="{{#external_value:publishedat}}" /> | <meta itemprop="uploadDate" content="{{#external_value:publishedat}}" /> | ||
<meta itemprop="embedUrl" content="https://www.youtube.com/embed/ | <meta itemprop="embedUrl" content="https://www.youtube.com/embed/{{{1}}}?controls=2&modestbranding=1&rel=0" /> | ||
<!-- non-mandatory properties for google rich snippets --> | <!-- non-mandatory properties for google rich snippets --> | ||
<meta itemprop="duration" content="{{#external_value:duration}}" /> | <meta itemprop="duration" content="{{#external_value:duration}}" /> | ||
</div>{{#if: {{{4|}}} | | <br style="clear:{{{3|left}}};" /> }}{{#ifeq: | </div>{{#if: {{{4|}}} | | <br style="clear:{{{3|left}}};" /> }}{{#ifeq: | ||