Hello,
I am trying to trigger Mark as complete on media complete event but it is not working. I added following in footer.
jQuery(document).ready(function($){
$( 'body' ).delegate( '#mark-complete', 'media_complete', function(event){
event.preventDefault();
$('#mark-complete').trigger('click');
setTimeout(function(){
jQuery('#next_unit').trigger('click');
var esc = jQuery.Event("keydown", { keyCode: 27 });
jQuery("body").trigger(esc);
},3000)
});
})
My course link is https://www.termainedavis.com/course/how-to-write-a-compelling-mission-statement/
I am trying that user did not click on next unit It will autoplay next unit.
Well this code only works with wordpress media player that is videos or audios added using wordpress add media popup .
If you are using it and still not working then please share url of the course ,unit name and admin credentials to check it