Widget:视频:修订间差异
来自HUIJIA FUN
Plurimod学生会(留言 | 贡献) 无编辑摘要 标签:已被回退 |
Plurimod学生会(留言 | 贡献) 无编辑摘要 标签:手工回退 |
||
| 第13行: | 第13行: | ||
}} | }} | ||
This widget | This widget lets you embed '''[https://github.com/etianen/html5media HTML5 Video Media]''' on your wiki page. | ||
It was created by [https://www.mediawikiwidgets.org/User:Taipan taipan]. | It was created by [https://www.mediawikiwidgets.org/User:Taipan taipan]. | ||
== Using this widget == | == Using this widget == | ||
For | For information on how to use this widget, see [https://www.mediawikiwidgets.org/Video widget description page on MediaWikiWidgets.org]. | ||
== Copy to your site == | == Copy to your site == | ||
To use this widget on your | To use this widget on your site, install [https://www.mediawiki.org/wiki/Extension:Widgets MediaWiki Widgets extension] and copy the [{{fullurl:{{FULLPAGENAME}}|action=edit}} complete source code] of this page to your wiki as page '''{{FULLPAGENAME}}'''. | ||
</noinclude><includeonly> | </noinclude><includeonly> | ||
<script src="//api.html5media.info/1.2.2/html5media.min.js"></script> | <script src="//api.html5media.info/1.2.2/html5media.min.js"></script> | ||
| 第27行: | 第27行: | ||
.video-container { | .video-container { | ||
position: relative; | position: relative; | ||
width: <!--{$width|default:425|validate:int|escape:'html'}-->px; | |||
height: px; | height: <!--{$height|default:355|validate:int|escape:'html'}-->px; | ||
margin-bottom: 15px; | margin-bottom: 15px; | ||
} | } | ||
.video-load-btn { | .video-load-btn { | ||
| 第47行: | 第43行: | ||
cursor: pointer; | cursor: pointer; | ||
z-index: 10; | z-index: 10; | ||
} | } | ||
.video-load-btn:hover { | .video-load-btn:hover { | ||
| 第55行: | 第48行: | ||
} | } | ||
.video-player { | .video-player { | ||
width: 100%; | |||
height: 100%; | |||
display: none; | display: none; | ||
} | } | ||
</style> | </style> | ||
<div class="video-container" | <div class="video-container"> | ||
<button class="video-load-btn" | <!-- Button will be removed after click --> | ||
onclick="this.nextElementSibling.style.display='block'; this.nextElementSibling.src=''; this.remove()"> | <button class="video-load-btn" | ||
onclick="this.nextElementSibling.style.display='block'; this.nextElementSibling.src='<!--{$url|validate:url|escape:html|regex_replace:"#^(?!(https?:)?//).*#i":''}-->'; this.remove()"> | |||
▶ Load Video | ▶ Load Video | ||
</button> | </button> | ||
<video class="video-player" | <!-- Video element (hidden by default) --> | ||
width="" | <video class="video-player" | ||
height="" | width="<!--{$width|default:425|validate:int|escape:'html'}-->" | ||
controls | height="<!--{$height|default:355|validate:int|escape:'html'}-->" | ||
controls | |||
preload="none"></video> | preload="none"></video> | ||
</div> | </div> | ||
</includeonly> | </includeonly> | ||
2025年7月5日 (六) 03:47的版本
{{#widget:视频
|url=https://vip.123pan.cn/1826204916/5651071
|width=640
|height=auto
}}
This widget lets you embed HTML5 Video Media on your wiki page.
It was created by taipan.
Using this widget
For information on how to use this widget, see widget description page on MediaWikiWidgets.org.
Copy to your site
To use this widget on your site, install MediaWiki Widgets extension and copy the complete source code of this page to your wiki as page Widget:视频.