Friday , March 23 2018
Home / Web Technologies / HTML5 / Lesson 11:HTML5 Audio Tag

Lesson 11:HTML5 Audio Tag

HTML5 Audio Tag:

HTML5 provides a standard for playing audio files.

Audio on the Web
Until now, there has not been a standard for playing audio files on a web page.Today, most audio files are played through a plug-in (like flash). However,different browsers may have different plug-ins. HTML5 defines a new element which specifies a standard way to embed an audio file on a web page: the <audio> element.

Browser Support
Internet Explorer 9, Firefox, Opera, Chrome, and Safari support the <audio> element.
Note: Internet Explorer 8 and earlier versions, do not support the <audio> element.
HTML5 Audio – How It Works
To play an audio file in HTML5, this is all you need:

The control attribute adds audio controls, like play, pause, and volume.You should also insert text content between the <audio> and </audio> tags for browsers that do not support the <audio> element.The <audio> element allows multiple <source> elements. <source> elements can link to different audio files. The browser will use the first recognized format.

Audio Formats and Browser Support

Currently, there are 3 supported file formats for the <audio> element: MP3,Wav, and Ogg:

Video Formats and Browser Support
no Browser MP4 WebM Ogg
1 Internet Explorer 9 Yes No No
2 Firefox No Yes Yes
3 Google Chrome Yes Yes Yes
4 Apple Safari Yes Yes No
4 Opera No Yes Yes


HTML5 Audio Tags and Description

Video Formats and Browser Support
no Tag Description
1 audio Defines sound content
2 source Defines multiple media resources for media elements



Print Friendly, PDF & Email

Give us your valuable feedback


About Murali

Hello everyone I am Software Developer having 3+ years of Experience in Microsoft Technologies and Others. My skills :-, C#,, SQL SERVER, web services, windows Service,Windows applications,HTML,CSS, JavaScript,JQuery,AnjularJs

Check Also

Lesson 14:HTML5 New Form Input Types Example-2

HTML5 New Form Inputs Example: [crayon-5ab4001bdcceb119008333/]   Related Give us your valuable feedback comments

%d bloggers like this: