Straightforward HTML5 video tag with several video types, but only the poster displays in Mac/Safari. What am I missing?
<video poster="~/images/image.jpg" preload="none">
<source src="myvideo.mp4" type="video/mp4" />
<source src="myvideo.webm" type="video/webm" />
<source src="myvideo.ogv" type="video/ogg" />
</video>
UPDATE - I know the tag is missing autoplay, but this is stuck in after the fact using JQuery. "viewport" is my variable that knows pixel width of the browser window.
if (viewport >= 768 && $(".videoInline video")[0]) {
$(".videoInline video")[0].load();
$(".videoInline video")[0].autoplay = true;
$(".videoInline video")[0].loop = true;
$(".videoInline video").get(0).play();
}
UPDATE 2 - to clarify, this is NOT iOS, it is Mac/Safari as stated above. So, desktop only.
https://developer.apple.com/library/safari/documentation/AudioVideo/Conceptual/Using_HTML5_Audio_Video/AudioandVideoTagBasics/AudioandVideoTagBasics.html – Meher Jebali Sep 17 '15 at 14:28