EDIT I have changed some Javascript now, so if I can find a javascript function that detects HTML5 Video support, it should work.
I have a HTML5 video player that has flash fallback, if HTML5 isnt supported, I want it to fallback to flash. Im currently using
<!--[if !IE]><!--> then load my custom player
else use SWFObject to render it.
Is it possible to do the folllowing:
` If (HTML5 supported browser) {
<some html and script> (My custom player)
}else{
<different html and script> (I would call SWFobject here)
}
`
Trying to find a nice easy solution idea.
Usually I would be able to have an additional <object>
in the video tag, but this won't be possible due to the way the player is inserted into the page.
Even though I can detect HTML5 support with a possibly unreliable method, I'm not sure how to have my HTML based on the output of the support
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…