HTML <video> Tag

Example Play a video: <video width=”320″ height=”240″ controls> <source src=”movie.mp4″ type=”video/mp4″> <source src=”movie.ogg” type=”video/ogg”> Your browser does not support the video tag. </video> Try it Yourself » Definition and Usage The <video> tag specifies video, such as a movie clip or other video streams. Currently, there are 3 supported video formats for the <video> element: MP4, WebM, and Ogg: Browser MP4 WebM […]

HTML <video> preload Attribute

Example Author thinks that the video should NOT be loaded when the page loads: <video controls preload=”none”> <source src=”movie.mp4″ type=”video/mp4″> Your browser does not support the video tag. </video> Try it Yourself » Definition and Usage The preload attribute specifies if and how the author thinks that the video should be loaded when the page loads. The preload […]

HTML <video> autoplay Attribute

Example A video that will automatically start playing: <video controls autoplay> <source src=”movie.mp4″ type=”video/mp4″> Your browser does not support the video tag. </video> Try it Yourself » Definition and Usage The autoplay attribute is a boolean attribute. When present, the video will automatically start playing as soon as it can do so without stopping. Browser Support The numbers […]

HTML <audio> autoplay Attribute

Example An audio file that will automatically start playing: <audio controls autoplay> <source src=”horse.mp3″ type=”audio/mpeg”> Your browser does not support the audio element. </audio> Try it Yourself » Definition and Usage The autoplay attribute is a boolean attribute. When present, the audio will automatically start playing as soon as it can do so without stopping. Browser Support The […]