``` More examples are included at the bottom of this page."> ``` More examples are included at the bottom of this page." />
Easy Tutorial
❮ Prop Fileupload Value Met Audio Addtexttrack ❯

onpause Event

Event Object

Example

Execute JavaScript when the video is paused:

<video onpause="myFunction()">

More examples are included at the bottom of this page.


Definition and Usage

The onpause event is triggered when the video/audio (audio/video) is paused.

Tip: The onplay event is triggered when the video/audio (audio/video) starts playing.


Browser Support

The numbers in the table specify the first browser version that fully supports the event.

Event Chrome IE Firefox Safari Opera
onpause Yes 9.0 Yes Yes Yes

Syntax

In HTML:

In JavaScript:

In JavaScript, using the addEventListener() method:

Note: The addEventListener() method is not supported in Internet Explorer 8 and earlier versions.


Bubbles: No
Cancelable: No
--- ---
Event Type: Event
--- ---
Supported HTML Tags: <audio>, <video>
--- ---

More Examples

Example

Execute JavaScript when the audio is paused:

<audio onpause="myFunction()">

❮ Prop Fileupload Value Met Audio Addtexttrack ❯