Widget:视频:修订间差异
来自HUIJIA FUN
Plurimod学生会(留言 | 贡献) 无编辑摘要 标签:已被回退 |
Plurimod学生会(留言 | 贡献) 无编辑摘要 标签:已被回退 |
||
| 第25行: | 第25行: | ||
<script src="//api.html5media.info/1.2.2/html5media.min.js"></script> | <script src="//api.html5media.info/1.2.2/html5media.min.js"></script> | ||
<style> | <style> | ||
.video-container { | |||
position: relative; | |||
width: <!--{$width|default:425|validate:int|escape:'html'}-->px; | |||
height: <!--{$height|default:355|validate:int|escape:'html'}-->px; | |||
margin-bottom: 15px; | |||
} | |||
.video-load-btn { | |||
position: absolute; | |||
top: 50%; | |||
left: 50%; | |||
transform: translate(-50%, -50%); | |||
padding: 10px 20px; | |||
background: #4285f4; | |||
color: white; | |||
border: none; | |||
border-radius: 4px; | |||
cursor: pointer; | |||
z-index: 10; | |||
} | |||
.video-load-btn:hover { | |||
background: #3367d6; | |||
} | |||
.video-player { | |||
width: 100%; | |||
height: 100%; | |||
display: none; | |||
} | |||
</style> | </style> | ||
<div class="video-container"> | <div class="video-container"> | ||
<div class="video-button-wrapper" style="text-align: center; padding: 20px;"> | |||
<button class="video-load-btn" | |||
onclick="this.closest('.video-container').querySelector('.video-player').style.display='block'; this.closest('.video-container').querySelector('.video-player').src=''; this.parentNode.remove()"> | |||
▶ Load Video | |||
</button> | |||
</div> | |||
<video class="video-player" | |||
width="" | |||
height="" | |||
controls | |||
preload="none"></video> | |||
</div> | </div> | ||
</includeonly> | </includeonly> | ||
2025年7月5日 (六) 03:56的版本
{{#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:视频.