HTMLVideoElement

< dom
Jump to: navigation, search

HTMLVideoElement

This page has been flagged with the following issues:

High-level issues:



Summary

The HTML <video> element is used to embed video content in an HTML or XHTML document.

Inherits from HTMLMediaElement

Properties

API Name Summary
height
initialTime Earliest point in seconds where the playback can (should) start playing
poster Valid URL to an image ressource that will be displayed until the first frame of the video is available or will be displayed if no valid video ressource is available at all.
videoHeight
videoWidth
width


Methods

No methods.

Events

No events.

Inherited from HTMLMediaElement

Properties

API Name Summary
audioTracks
autobuffer
autoplay
buffered
controls
currentSrc
currentTime
defaultPlaybackRate
duration
ended
error
loop
muted
networkState
paused
playbackRate
played
preload
seekable
seeking
src
textTracks
volume

Methods

API Name Summary
canPlayType
load
pause
play Loads and starts playback of a media resource.

Events

API Name Summary
canplay Fires whenever enough data is available to determine whether a media is playable.
canplaythrough Fires when enough data is available to determine whether a media is playable at a normal rate without interruptions.
progress Fires to indicate progress while downloading media data.

Examples

View live exampleA simple example of showing a video

HTML

<p>This is big buck bunny video.</p>
<video width="350" height="240" controls>
<source src="http://mirrorblender.top-ix.org/peach/bigbuckbunny_movies/big_buck_bunny_480p_stereo.ogg" type="video/ogg">
</video>

Usage

Currently, there are 3 supported video formats for the <video> element: MP4, WebM, and Ogg



Compatibility

Desktop

Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari
Basic support ? ? ? ? ?

Mobile

Feature Android BlackBerry Chrome for mobile Firefox Mobile (Gecko) IE Mobile Opera Mobile Opera Mini Safari Mobile
Basic support ? ? ? ? ? ? ? ?