This page is In Progress

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.

audio

Summary

The audio object is part of the HTML5 audio api. It extends the <audio> tag and allows users to access audio data. This enables the ability to manipulate or create new audio data.

Inherits from HTMLAudioElementHTMLAudioElement

Properties

No properties.

Methods

No methods.

Events

No events.

Inherited from HTMLAudioElement

Properties

No properties.

Methods

No methods.

Events

No events.

Notes

Beginning with Internet Explorer 9, any audio or video content needs the correct mime type set on the server, or the files won't play. Internet Explorer 9 and Internet Explorer 10 support MP3 audio, and MP4 audio and video. WebM audio and video files can be supported by installing the WebM components from The WebM project. The following table shows the required settings for your web server to host these files correctly.

Media file to serve Extension setting Mime type setting
Audio mp3 mp3 audio/mpeg
Audio mp4 m4a audio/mp4
Audio WebM webm audio/webm
Video mp4 mp4 video/mp4
Video webm webm video/webm


Related specifications

A vocabulary and associated APIs for HTML and XHTML






Attributions