When video ended it should trigger the ended event once.
When video ended it is triggering the ended event twice.
var jqueryPlayer = new Vimeo.Player($('.embed-responsive-item'));
jqueryPlayer.ready().then(function() {
jqueryPlayer.on('ended', function(data) {
seconds = data.seconds;
duration = data.duration;
percent = data.percent;
url = '/lecture/student/progress';
if(data.percent = 1){
sendAjaxCall(url, seconds, duration, percent);
}
});
)}
http://repto.com.bd/course/youtube-branding-for-businesspart-1-by-debazitdatta/lecture/117
or any video from this site,, you will be some free courses there too.
I am also having this issue.
A Fiddle to test ended event:
http://jsfiddle.net/jybleau/k2onbpzh/
Thanks for the issue report! We are working to resolve this now and will update the ticket when the fix is rolled out.
this should be resolved. thanks again for the report.
@jybleau this is how i am doing it. Updated the question. It didn't solve the problem. My vimeo version is 3.4.
same issue here with version: "@vimeo/player": "^2.12.2"
same issue here with version: "@vimeo/player": "^2.12.2"
@adrielwerlich make sure you're compiling the latest version and maybe check with the fiddle link above, it's using 2.12.2 and the end event is triggered once as expected.
Most helpful comment
this should be resolved. thanks again for the report.