221222 항해99 46일차 <video> tag

요니링 컴터 공부즁·2022년 12월 24일
0
post-custom-banner
  • This is a new feature introduced in HTML for embedding video and incorporating movie files and video streaming. It is done using the <video> tag, which supports three video formats currently.
    • MP4
    • Ogg and
    • WebM
  • Out of these three formats, the most common format in which all the browsers (such as Internet Explorer, Google Chrome, Firefox, Safari, Opera) supports is the mp4 file format.

Attributes

  • src: This is used to set the URL or path from where the video file will get fetched.
  • autoplay: This attribute specifies that as soon as your web page gets ready, the video embedded in your page gets played at that moment.
  • controls: This tells the browser what player-controls / buttons (such as play/pause, etc.) to be displayed on the page with the video.
  • width and height: This is used to assign the player's width and height in which the video will be shown.
  • muted: This tells whether the audio part of the specified video should be kept mute or not.
<video width="320" height="240" controls autoplay muted>
    <source src="video.mp4" type="video/mp4">
    <source src="video.ogg" type="video/ogg">
</video>

참조:
HTML Video Tag

post-custom-banner

0개의 댓글