What is Audio and Video tags in HTML?
Audio Tag:-
The "audio" tag is an inline element that is used to embed sound files into a web page. Currently, there are three supported file formats for HTML5 audio tag 1.mp3 2.wav 3.ogg
Audio Tag Attributes:-
Controls:- It defines the audio controls which is displayed with Play/Pause buttons.
Autoplay:- It specifies that the audio will start playing as soon as it is ready.
Loop:- It specifies that the audio file will start over again, every time when it is completed.
Muted:- It is used to mute the audio output.
Preload:- It specifies the author's view to upload an audio file when the page loads
Src:- It specifies the source URL of the audio file.
Video Tag:-
It is used to embed a video on a web page. There are three different formats that are commonly supported by web browsers. 1.mp4, 2.ogg, 3.WebM
Attributes of HTML Video Tag:-
Controls:- It defines the video controls which is displayed with Play/Pause buttons.
Height:- It is used to set the height of the video player.
Width:- It is used to set the width of the video player.
Poster:- It specifies the image which is displayed on the screen when the video is not played.
Autoplay:- It specifies that the video will start playing as soon as it is ready.
Loop:- It specifies that the video file will start over again, every time when it is completed.
Muted:- It is used to mute the video output.
Preload:- It specifies the author's view to upload a video file when the page loads.
Src:- It specifies the source URL of the video file.