HTML and CSS Reference
In-Depth Information
kind="subtitles|captions|descriptions|chapters|metadata"
Indicates the intended purpose of the external track resource.
subtitles
provide a tran-
scriptionortranslationofdialoguethatdisplayoveravideo;
captions
provideacomplete
description of the audio (including sound effects and other audio cues) for when audio is
not available or for the hard-of-hearing;
descriptions
indicates the resource is an audio
track that describes what is happening in a video when it cannot be viewed;
chapters
are
chapter titles used for navigating the media resource; and
metadata
is a track intended to
be used by scripts but are not displayed. The default is
subtitles
.
label="
text string
text string
"
Provides a title for the track that may be displayed by the browser.
src="
URL
URL
"
Required
. Provides the location of the text track data.
srclang="
2-letter language code
2-letter language code
"
Required for subtitles
. Specifies the language of the text track data.
Example
<video src="blockbuster.webm">
<track kind="subtitles" src="blockbuster.en.vtt"
srclang="en" label="English">
<track kind="subtitles" src="blockbuster.de.vtt"
srclang="de" label="Deutsch">
</video>