Define Audio and Video Media Event in HTML5

In this article I will explain Audio and Video Media Event in HTML5.
  • 1216

Audio and Video Handling Media Events

The HTML5 audio and video tag can have a number of attributes to control various functionality of the control using Javascript:

  • abort This event is generated when playback is aborted.

  • canplay This event is generated when enough data is available that the media can be played.

  • ended  This event is generated when playback completes.

  • error This event is generated when an error occurs.

  • loadeddata This event is generated when the first frame of the media has finished loading.

  • loadstart This event is generated when loading of the media begins.

  • pause This event is generated when playback is paused.

  • play This event is generated when playback starts or resumes.

  • progress This event is generated periodically to inform the progress of the downloading the media.

  • ratechange This event is generated when the playback speed changes.

  • seeked This event is generated when a seek operation completes.

  • seeking This event is generated when a seek operation begins.

  • suspend This event is generated when loading of the media is suspended.

  • volumechange This event is generated when the audio volume changes.

  • waiting This event is generated when the requested operation (such as playback) is delayed pending the completion of another operation (such as a seek)

  • stalled The user agent is trying to fetch media data, but data is unexpectedly not forthcoming. 

  • loadedmetadata The user agent has just determined the duration and dimensions of the media resource .

  • timeupdate The current playback position changed as part of normal playback or in an especially interesting way, for example discontinuously.

  • durationchange The duration attribute has just been updated.

  • canplaythrough The user agent estimates that if playback were to be started now, the media resource could be rendered at the current playback rate all the way to its end without having to stop for further buffering. 

Further Readings

You may also want to read these related articles :

Ask Your Question 

Got a programming related question? You may want to post your question here

Programming Answers here

© 2013 dotNetheaven. All rights reserved.