I am using a HTML video TAG to be able to show video on my website, I had enabled the function autoplay, but then the video would play on page reload. So I removed the autoplay function and I have:
<video width="600" height="315" style=" margin-bottom: 20px;" controls >
<source src="video/handi.mp4" type="video/mp4">
</video>
<script>
$('body').on('hidden.bs.modal', '.modal', function () {
$('video').trigger('pause');
});
</script>
This works well, but now when U open a modal to watch a video it will play but you have to click on start playing button and when u close the modal it will pause the video when you stopped it, if you open the same modal you can resume the video from when it was stopped. Is there any function like auto play that when you open the modal it opens it and the video is played automatically and also I want to know if there is any reload function that when you u open any modal to watch the video it starts from the beginning not from where you stopped t.