Objeto de rastreamento HTML DOM
Rastrear objeto
O objeto Track representa um elemento HTML <track>.
Acessar um objeto de rastreamento
Você pode acessar um elemento <track> usando getElementById():
var x = document.getElementById("myTrack");
Criar um objeto de rastreamento
Você pode criar um elemento <track> usando o método document.createElement():
var x = document.createElement("TRACK");
Propriedades do objeto de rastreamento
Property | Description |
---|---|
default | Sets or returns the default state of the track |
kind | Sets or returns the value of the kind attribute of the track |
label | Sets or returns the value of the label attribute of the track |
readyState | Returns the current state of the track resource |
src | Sets or returns the value of the src attribute of the track |
srclang | Sets or returns the value of the srclang attribute of the track |
track | Returns a TextTrack object representing the track element's text track data |
Propriedades e eventos padrão
O objeto Track também suporta as propriedades e eventos padrão .
Páginas relacionadas
Referência HTML: tag HTML <track>