HTML onplay Attribute
HTML onplay Attribute
The onplay attribute defines a script to be run when the audio or video is just started or is no longer paused. Its opposite is onpause attribute. The onpause attribute is used to define a script to be run when the audio or video is paused either programmatically or by the user.
Used With:-
Elements | Event |
---|---|
audio | play |
video | play |
Syntax:-
Its syntax is:- < element onplay="your_script" >