#27 HTML Audio Control

HTML Audio tag provides you to embedding an audio file on a web page.

autoplay attribute allow audio to play automatically. <audio autoplay>

Add muted after autoplay to let your audio file start playing automatically (but muted). <audio controls autoplay muted>

Tag

tag defines multiple resource elements. For audio control the resource element is nothing but your sound file.

This sound file is specified with the help of name and it type.

Example

See the Pen audio tag by Arpit (@soniarpit) on CodePen.

Previous: #26 HTML Input form* Attributes

Next: #28 HTML Video Control