ontimeupdate event
Occurs to indicate the current playback position.
![]() ![]() |
Syntax
| HTML Attribute | <element ontimeupdate = "handler(event)"> |
|---|---|
| Event Property | object.ontimeupdate = handler; |
| attachEvent Method | object.attachEvent("ontimeupdate", handler) |
| addEventListener Method | object.addEventListener("timeupdate", handler, useCapture) |
Event information
| Synchronous | No |
|---|---|
| Bubbles | No |
| Cancelable | No |
Event handler parameters
- pEvtObj [in]
-
Type: Event
Standards information
- HTML5 A vocabulary and associated APIs for HTML and XHTML, Section 4.8.9.12
Remarks
Use the IHTMLMediaElement::currentTime property to retrieve the current playback position. For the total length of the audio or video clip, use IHTMLMediaElement::duration.
To invoke this event, do one of the following:
- Play the video.
- Move the position indicator on the playback controls.
Note This event is fired approximately four times a second.
See also
- Reference
- IHTMLMediaElement::currentTime
- IHTMLMediaElement::duration
- How to use HTML5 to play video files on your webpage
- How to use HTML5 to Add an Audio Player to your Webpage
- Make your videos accessible with Timed Text Tracks
- ondurationchange
Build date: 11/12/2012

