audio elementcontrols attribute: Interactive content.controls attribute: Palpable content.src attribute: zero or more track elements, then transparent, but with no media element descendants.src attribute: zero or more source elements, then zero or more
track elements, then transparent, but with no media element descendants.srccrossoriginpreloadautoplaymediagrouploopmutedcontrols
[NamedConstructor=Audio(),
NamedConstructor=Audio(DOMString src)]
interface HTMLAudioElement : HTMLMediaElement {};
An audio
element represents
a sound or audio stream.
Content may be provided inside the audio
element; it is intended for older Web browsers which do not support
audio,
so that legacy audio plugins can be tried, or to show text to the
users of these older browsers informing them of how to access the
audio contents.
In particular, this content is not intended to
address accessibility concerns. To make audio content accessible to
the deaf or to those with other physical or cognitive disabilities,
a variety of features are available. If captions or a sign language
video are available, the video
element can be used instead of the audio
element to play the audio, allowing users to enable the visual
alternatives. Chapter titles can be provided to aid navigation,
using the track element and a
caption file.
And, naturally, transcripts or other textual alternatives can be
provided by simply linking to them in the prose near the
audio
element.
The audio
element is a media element whose media data is ostensibly audio data.
The src, preload, autoplay, mediagroup, loop, muted, and controls attributes are the attributes common to all media
elements.