audio (HTML5)

The audio element is used to embed sound content in an HTML or XHTML document.

Properties & Events

KeyDescriptionAvailability
autobufferA Boolean attribute; if specified, the audio will automatically begin being downloaded, even if not set to automatically play.
chrome 3.0safari ??Firefox 3.6ie 9.0opera 10.5
autoplayA Boolean attribute; if specified (even if the value is "false"!), the audio will automatically begin to play back as soon as it can do so without stopping to finish loading the data.
chrome 3.0safari ??Firefox 3.6ie 9.0opera 10.5
bufferedAn attribute you can read to determine which time ranges of the media have been buffered.
chrome 3.0safari ??Firefox 3.6ie 9.0opera 10.5
controlsIf this attribute is present, the browser will offer controls to allow the user to control audio playback, including volume, seeking, and pause/resume playback.
chrome 3.0safari ??Firefox 3.6ie 9.0opera 10.5
loopA Boolean attribute; if specified, we will, upon reaching the end of the audio, automatically seek back to the start.
chrome 3.0safari ??Firefox 3.6ie 9.0opera 10.5
mozcurrentsampleoffsetThe offset, specified as the number of samples since the beginning of the audio stream, at which the audio is currently playing.
chrome 3.0safari ??Firefox 3.6ie 9.0opera 10.5
mutedA Boolean attribute which indicates whether the audio will be initially silenced.
chrome 3.0safari ??Firefox 3.6ie 9.0opera 10.5
preloadThis enumerated attribute is intended to provide a hint to the browser about what the author thinks will lead to the best user experience.
chrome 3.0safari ??Firefox 3.6ie 9.0opera 10.5
srcThe URL of the audio to embed.
chrome 3.0safari ??Firefox 1.0ie 1.0opera 1.0

Examples having uses of: 'audio'

1 votes
10k views

HTML5 source

The <source> tag is used to specify multiple media resources for media elements, such as <video> and <audio>. The <source> tag allows you to specify alternative video/audio files which the browser may choose from, based on its media type or codec support.
4 votes
8k views

HTML5 audio

The <audio> tag defines sound, such as music or other audio streams. Tip: Any text inside the between <audio> and </audio> will be displayed in browsers that do not support audio.
0 votes
0 views

The HTML5 source tag

The <source> tag is used to specify multiple media resources for media elements, such as <video> and <audio>. The <source> tag allows you to specify alternative video/audio files which the browser may choose from, based on its media type or codec support.