You can do this:
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<video id="v1" width="320" height="240" controls="controls" onended="vidplay(2)">
<source src="http://content.bitsontherun.com/videos/bkaovAYt-52qL9xLP.mp4"type="video/mp4">
<object data="" width="320" height="240">
<embed width="320" height="240" src="Yes Bank Advertisment.mp4">
</object>
</video>
<video id="v2" width="320" height="240" controls="controls" onended="vidplay(1)">
<source src="http://content.bitsontherun.com/videos/bkaovAYt-52qL9xLP.mp4"type="video/mp4">
<object data="" width="320" height="240">
<embed width="320" height="240" src="Yes Bank Advertisment.mp4">
</object>
</video>
<script type="text/javascript">
var video = document.getElementById("v1");
video.play();
function vidplay(i) {
var video = document.getElementById("v"+i);
if (video.paused) {
video.play();
} else {
video.pause();
}
};
</script>
</body>
</html>
I've edited here and it works perfectly, stay on one side of the other! one at a time, see if it helps you
I need to make javascript control this, I used the onended tag that performs a function call when the video ends