when complicated operations are being carried out. You can find more information about
Before HTML5 it was notoriously difficult to display audio and video in browsers, and plu-
gins such as Flash often had to be used. HTML5 introduced the <audio> and <video>
tags used to insert audio and video clips into a web page. It also introduced a Media API
An audio clip can be inserted into a page with the <audio> tag, using the src attribute
to point to the audio file:
<audio src="/song.mp3" controls>
Your browser does not support the audio element.
A video clip can be inserted with the <video> tag, using the src attribute to point to the
<video src="http://movie.mp4" controls>
Your browser does not support the video element.
Any content inside the <audio> or <video> tags will only display if the browser does
not support them; hence, it can be used to display a message to users of older browsers
without support for these features. The controls attribute can be added (without any
value) and will display the browser's native controls, such as play, pause, and volume con-
trol, as can be seen in the screenshot in Figure 14.4 .
Search WWH ::