track element | track object
Provides a way for authors to specify one or more timed text track resources for video elements. For more information on using the track element and object, see track object
![]() |
Syntax
<track kind="subtitles" src="enTrack.vtt" srclang="en" label="English">
DOM Information
Inheritance Hierarchy
Members
The track object has these types of members:
Events
The track object has these events.
| Event | Description |
|---|---|
| oncuechange |
Occurs when a TextTrackCue in a HTMLTrackElement changes. |
Properties
The track object has these properties.
| Property | Access type | Description |
|---|---|---|
|
Read/write |
Gets or sets the default timed text track to use when multiple track elements are specified for a video element. | |
|
Read/write |
Gets or sets the type or category of the timed text track associated with a track element. | |
|
Read/write |
Gets or sets the label attribute to create a user readable title for an audio, video, or text track. | |
|
The address or URL of the a media resource (video, audio) that is to be considered. | ||
|
Read/write |
Gets or sets the language of the text track data. This attribute is required if "subtitles" is specified in the kind attribute. | |
|
Read-only |
Returns the TextTrack object that corresponds to a track element. |
See also
