Widget:YouTube — различия между версиями
WikiSysop (обсуждение | вклад) |
WikiSysop (обсуждение | вклад) |
||
Строка 14: | Строка 14: | ||
* '''playlist''' - playlist name (starts with PL) - first clip is played ('''id''' is ignored) | * '''playlist''' - playlist name (starts with PL) - first clip is played ('''id''' is ignored) | ||
* '''width''' and '''height''' define view dimensions, 350x267 is default | * '''width''' and '''height''' define view dimensions, 350x267 is default | ||
− | </noinclude><includeonly><iframe width="<!--{$width|validate:int|default:350}-->" height="<!--{$height|validate:int|default:267}-->" src="http://www.youtube.com/embed/<!--{$id|escape:'urlpathinfo'}-->" frameborder="0" allowfullscreen></iframe></includeonly> | + | </noinclude><includeonly><iframe width="<!--{$width|validate:int|default:350}-->" height="<!--{$height|validate:int|default:267}-->" src="http://www.youtube.com/embed/<!--{$id|escape:'urlpathinfo'}-->" frameborder="0" allowfullscreen></iframe><br />Описание видео <div class="floatright">[[Файл:Magnify-clip.png|15px|справа|Открыть в отдельном окне|link=http://youtu.be/<!--{$id|escape:'urlpathinfo'}-->]]</div></includeonly> |
Версия 13:20, 30 июля 2014
Виджет для вставки видео с YouTube на страницу. Автор виджета: Yaron Koren.
Для вставки используйте следущий код:
Содержание
Использование
Одно видео
{{#widget:YouTube|id=Ukytqe9pwDM}}
Плейлист
{{#widget:YouTube|playlist=PL6FD8256CD24CFF1F}}
Параметры
- id - video id (from the URL)
- playlist - playlist name (starts with PL) - first clip is played (id is ignored)
- width and height define view dimensions, 350x267 is default