W3cubDocs

/DOM

HTMLTrackElement.src

The HTMLTrackElement.src property reflects the value of the <track> element's src attribute, which indicates the URL of the text track's data.

Syntax

var textTrackURL = HTMLTrackElement.src;

Value

A DOMString object containing the URL of the text track data.

Example

// coming soon

Specifications

Browser compatibilityUpdate compatibility data on GitHub

Desktop
Chrome Edge Firefox Internet Explorer Opera Safari
Basic support 23 Yes 31
31
Setting the src property did not work properly in versions prior to 50.
24 — 30
Disabled
Disabled From version 24 until version 30 (exclusive): this feature is behind the media.webvtt.enabled preference (needs to be set to true). To change preferences in Firefox, visit about:config.
No 12 Yes
Mobile
Android webview Chrome for Android Edge Mobile Firefox for Android Opera for Android iOS Safari Samsung Internet
Basic support Yes 25 Yes 31
31
Setting the src property did not work properly in versions prior to 50.
24 — 30
Disabled
Disabled From version 24 until version 30 (exclusive): this feature is behind the media.webvtt.enabled preference (needs to be set to true). To change preferences in Firefox, visit about:config.
12 Yes ?

See also

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/src