Quantcast
Channel: Adobe Community: Message List
Viewing all articles
Browse latest Browse all 97529

Re: stop and start video commands?

$
0
0

Hi Rich,

 

Animate's timelines have stop() and play() methods - but video (and audio) elements must be explicitly addressed and do not have a stop() method.

 

To "stop" a video on a click event, you'd use something like this:

 

sym.$(my_video_element)[0].pause();

 

To "stop it at its beginning" so that replaying it would start from the beginning, you'd use two lines of code:

 

sym.$(my_video_element)[0].pause();

sym.$(my_video_element)[0].currentTime = 0;

 

hth,

Joe


Viewing all articles
Browse latest Browse all 97529

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>