Ver Mensaje Individual
  #6 (permalink)  
Antiguo 22/02/2015, 07:22
merops
 
Fecha de Ingreso: enero-2015
Mensajes: 33
Antigüedad: 9 años, 3 meses
Puntos: 0
Respuesta: crear un reproductor de video con botones propios

encotre el codigo,
pero no entiendo la function restar, y tampoco me deja introducir en vez de el texto, una imagen al boton jpg
¿alguna idea?
os pongo el codigo
Cita:
<!DOCTYPE HTML>
<html>
<head>
<style type="text/css">
video1 {
position: absolute;
width: 205px;
height: 154px;
}
</style>

</head>
<script type="text/javascript">

function vidplay() {
var video = document.getElementById("Video1");
var button = document.getElementById("play");
if (video.paused) {
video.play();
button.textContent = "||";
} else {
video.pause();
button.textContent = ">";
}
}

function restart() {
var video = document.getElementById("Video1");
video.currentTime = 0;
}

function skip(value) {
var video = document.getElementById("Video1");
video.currentTime += value;
}
</script>

</head>
<body>

<video id="Video1" >

<source src="video.mp4" type="video/mp4" />


</video>

<section >

<div id="buttonbar">

<button id="rew" onclick="skip(-10)">&lt;&lt;</button>
<button id="play" onclick="vidplay()">&gt;</button>
<button id="fastFwd" onclick="skip(10)">&gt;&gt;</button>
</div>

</section>
</body>
</html>