1

Is there a ready to use code or some sort to enable the fullscreen button on Safari for the ?video? Currently when the video is loaded, and click on it doesnt work.

<video width="320" height="240" controls="controls" name="media" src="urlvideo">Text</video>

What types are supported for the video tag? Do i need to use type=audio/mp3 for playing mp3 and type=audio/wav etc....?

By they way, the video ui looks different on each browser or not working at all... is there a way to have them all the same look and feel and have them all work on all browsers?

CCCam
  • 85
  • 3
  • 10
  • [Dive Into HTML 5](http://diveintohtml5.ep.io/video.html) has a good tutorial on all the nuances of this. – someone Oct 10 '11 at 21:32

3 Answers3

0

purely css, you can target it with video::-webkit-media-controls-fullscreen-button{}, and you'll want to reference this http://codesearch.google.com/codesearch/p#OAMlx_jo-ck/src/third_party/WebKit/Source/WebCore/css/mediaControls.css

albert
  • 8,112
  • 3
  • 47
  • 63
0

To play video when user clicks on it:

    document.querySelctor('video').addEvenetListenr('click', function(){
         this.play()
    }, false);

To have fullscreen use Webkit and Gecko full screen API

Mohsen
  • 64,437
  • 34
  • 159
  • 186
0

First, not all browsers have the same video codecs, so not all browsers can play the same videos. I would suggest looking here to choose a format that is supported by the browsers you are targeting:
HTML5 Video Codec Support By Browser


For Safari specifically, I have gotten this JavaScript to work to get a video to play fullscreen:

var vid = document.getElementById('video');
vid.webkitEnterFullscreen();
vid.play();

Also, check out this thread: Web App - iPad webkitEnterFullscreen - Programatically going full-screen video

Hope that helps!

Community
  • 1
  • 1
Brett H
  • 1,168
  • 10
  • 14