For a current project, I am in need of rendering a centered image (a play button) at runtime on top of a video based on the UserAgent. If the userAgent is not Firefox, I want to display the image as Firefox has its own playEvent and button on top of the video at the start. Unfortunately, all my previous attempts have been unsuccessful.
I have tried:
- Adding an image tag inside the video tag and setting the z-index to 10 while giving the video a z-index of 1
- Wrapping the video tag with a div containing a background image
Are there any alternative methods to achieve this? Please avoid suggesting the use of a poster image as I already have one that needs to be used.
-EDIT-
Code:
<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>