Horje

Example of HTML onended Event Attribute

It will alert that the audio has ended.
index.html
Example: HTML
<audio controls onended="myFunction()"> <source src="https://download.samplelib.com/mp3/sample-3s.mp3" type="audio/ogg"> <source src="https://download.samplelib.com/mp3/sample-3s.mp3" type="audio/mpeg"> Your browser does not support the audio element.
</audio>

Output should be:

Example of HTML onended Event Attribute




Type :
html
Category :
Web Tutorial
Sub Category :
HTML Media Events Attribute
Uploaded by :
Admin