MDN self-hosted library · e01.org

HTMLMediaElement: encrypted event

Encrypted Media Extensions

no runnable cells web-api-event upstream source

Encrypted Media Extensions

The encrypted event is fired when initialization data is found in the media that indicates it is encrypted.

This event is not cancelable and does not bubble.

Syntax

Use the event name in addEventListener():

addEventListener("encrypted", (event) => { })

Alternatively, assign to the event handler property of the interface:

onencrypted = (event) => { }

Event type

A MediaEncryptedEvent. Inherits from Event.

MediaEncryptedEvent

Specifications

Browser compatibility

See also

  • HTMLAudioElement
  • HTMLVideoElement
  • audio
  • video
  • MediaEncryptedEvent