<video width="320" height="240" autoplay>
<source src="movie.mp4" type="video/mp4">
<source src="movie.ogg" type="video/ogg">
Your browser does not support the video tag.
</video>
<html>
<head>
<title> page 1</title>
</head>
<body>
<h1>hello world</h1>
<p>this is the text</p>
var myVideo=document.getElementById("video1");
var videoList=['part_1.mp4','part_2.mp4','part_3.mp4','part_A.mp3','movie_bbb.ogg'];
var index = videoList.indexOf(window.currentVideoName);
//Next button
function nextButton(){
myVideo.pause();
myVideo.currentTime=0;
index = index + 1;
if(index==videoList.length)
index = 0;
alert(videoList[index]);
myVideo.src = 'C:/'+videoList[index];
window.currentVideoName=videoList[index];
myVideo.play();
}
function playPause()
<div style="text-align:center">
<button onclick="playPause()">Play/Pause</button>
<button onclick="nextButton()">Next</button>
<br>
<video id="video1" width="420">
<source src="C:/sample.mp4" type="video/mp4">
<source type="video/mp3">
<source type="video/ogg">
Your browser does not support HTML5 video.
</video>
</div>
</body>
</html>
<input type="file" id="txtfiletoread" />
you can get and set the filename to the array via this js code:var elm=document.getElementById('txtfiletoread');
elm.addEventListener('change',function(){
var a=this.value.split('\\');
a=a[a.length - 1];
videoList.push(a);
});