Instance code:
<video width= "height=" controls= "Controls" > <source src= "Movie.ogg" type= "Video/ogg" > <source src= "Movie.mp4" type= "Video/mp4" >your browser does not support the video tag.</video>
Properties of the <video> tag
Properties |
value |
Description |
AutoPlay |
AutoPlay |
If this property appears, the video plays as soon as it is ready. |
Controls |
Controls |
If this property appears, the control is displayed to the user, such as the play button. |
Height |
Pixels |
Sets the height of the video player. |
Loop |
Loop |
If this property appears, the media file starts playing again when it finishes playing. |
Preload |
Preload |
If this property appears, the video loads when the page loads and prepares to play. If you use "autoplay", the property is ignored. |
Src |
Url |
The URL of the video to play. |
Width |
Pixels |
Sets the width of the video player. |
html5--Video Playback