我怀疑我似乎没有弄清楚如何解决,基本上我有一个视频是我的网站的视频呈现,我想要的是,在视频开始播放前显示图像,所以我可以阻止用户在启动视频之前看到该循环,如果出现连接问题,图像将始终显示。
目前我有这个:
<section class="tp-banner-container content_section">
<div class="embed-responsive embed-responsive-16by9">
<iframe id="video" class="embed-responsive-item" src="https://www.youtube.com/embed/kn-1D5z3-Cs?autoplay=1&showinfo=0
&start=10&controls=0&modestbranding=1" volume="0">
</iframe>
</div>
</section>
答案 0 :(得分:0)
你需要充分利用attr海报并给出一些高度和宽度。
<video width="470" height="255" poster="placeholder.png" controls>
<source src="video.mp4" type="video/mp4">
<source src="video.ogg" type="video/ogg">
<source src="video.webm" type="video/webm">
<object data="video.mp4" width="470" height="255">
<embed src="video.swf" width="470" height="255">
</object>
</video>