好的项目我需要在运行时渲染一个居中的图像(播放按钮),取决于UserAgent的视频。如果userAgent不是Firefox,我想显示图像,因为Firefox在开始时有自己的playEvent和按钮。我之前所做的所有尝试都失败了。视频标签上的居中图像
我想:在视频标签
- 标签,并把z-index的10个,而把视频的z-index为1
- 把一个div与视频标签周围的背景图像
有没有其他的方法可以做到这一点,请不要回复使用海报,因为我已经有我需要使用的海报。
CNC中
代码:
<tr>
<td runat="server" width="680px" height="383px" id="vContainer">
<video id="player" style="z-index: 1" width="100%" height="100%" title="" controls runat="server">
<source runat="server" id="ffVideo" type="video/ogg" />
<source runat="server" id="mp4Video" type="video/mp4" />
</video>
<embed id="playerOld" width="680px" autostart="false" allowfullscreen="true" height="383px" title="" style="display: none" type="application/mp4" runat="server" />
</td>
</tr>
分享您的尝试。具有propper z-index的简单图层可以工作。 –
它应该和我可以在呈现的HTML中找到它在视频背后。 – DieVeenman
有没有''标签在哪里... –