Somehow, there are really little tutorials out there for html5 video and audio playback.
I simply want to embed video and audio files with customized controls. However, th开发者_如何学Pythone controls should be fairly simple. I only need a play-button. If clicked, play gets replaced by pause. That's all!
However, I even don't know how to embed/display a video without “preload controls”. Somehow, if I only set (without preload controls) Firefox doesn't even show anything. Chrome does show a black window.
I would love to be able to use jQuery to control the video play and pause button. Maybe you have some little start-approach for me!
Thank you very much!
It's basically all stated here: HTML 5 video custom controls
There's an article co-written by one of the authors (Bruce Lawson) of the above article which, if you scroll down to, shows you how to create your own controls: Introduction to HTML5 video.
You can do:
$('video').trigger('play');
$('video').trigger('pause');
For more: https://web.archive.org/web/20150411142822/http://wonderdesigners.com/?p=219
精彩评论