Reference Index > DOM HTML
HTMLMediaElement
Interface Specification
from https://html.spec.whatwg.org/multipage/media.html#media-elements
interface HTMLMediaElement
{
readonly attribute MediaError? error;
[CEReactions] attribute USVString src;
attribute MediaProvider? srcObject;
readonly attribute USVString currentSrc;
[CEReactions] attribute DOMString? crossOrigin;
const unsigned short NETWORK_EMPTY = 0;
const unsigned short NETWORK_IDLE = 1;
const unsigned short NETWORK_LOADING = 2;
const unsigned short NETWORK_NO_SOURCE = 3;
readonly attribute unsigned short networkState;
[CEReactions] attribute DOMString preload;
readonly attribute TimeRanges buffered;
void load();
CanPlayTypeResult canPlayType(DOMString type);
const unsigned short HAVE_NOTHING = 0;
const unsigned short HAVE_METADATA = 1;
const unsigned short HAVE_CURRENT_DATA = 2;
const unsigned short HAVE_FUTURE_DATA = 3;
const unsigned short HAVE_ENOUGH_DATA = 4;
readonly attribute unsigned short readyState;
readonly attribute boolean seeking;
attribute double currentTime;
void fastSeek(double time);
readonly attribute unrestricted double duration;
object getStartDate();
readonly attribute boolean paused;
attribute double defaultPlaybackRate;
attribute double playbackRate;
readonly attribute TimeRanges played;
readonly attribute TimeRanges seekable;
readonly attribute boolean ended;
[CEReactions] attribute boolean autoplay;
[CEReactions] attribute boolean loop;
Promise play();
void pause();
[CEReactions] attribute boolean controls;
attribute double volume;
attribute boolean muted;
[CEReactions] attribute boolean defaultMuted;
[SameObject] readonly attribute AudioTrackList audioTracks;
[SameObject] readonly attribute VideoTrackList videoTracks;
[SameObject] readonly attribute TextTrackList textTracks;
TextTrack addTextTrack(TextTrackKind kind, optional DOMString label = "", optional DOMString language = "");
};
};
Implementation status
Number of constants in JS interface: 9/9 Number of attributes in JS interface: 27/27 Number of functions in JS interface: 7/7Function Implementation status
load Dummy
canPlayType Dummy
fastSeek Dummy
getStartDate Dummy
play Dummy
pause Dummy
addTextTrack Dummy
Browser & Device compatibility
Device type Support Status Desktop PC browsers Yes
HBBTV 1.5 devices Yes
HBBTV 2.0.x devices Yes
Notes
none
This page has been generated automatically from source code by the CoyoteBrowser InfoTool on Tue Jan 05 16:54:08 2021
. Some design elements from MDN are used under CC-BY-SA license from "Mozilla Contributors".