var video = document.getElementById("play_video");
$(".playButton").click(function(){
if(video.paused){
video.play();
$(this).hide();
}
else{
video.pause();
$(this).attr(‘src‘, ‘{{media
url="video/video_pause.png"}}‘);
$(this).show();
}
})
$("#play_video").click(function(){
if(video.paused){
video.play();
$(".playButton").hide();
}
else{
video.pause();
$(".playButton").attr(‘src‘, ‘{{media
url="video/video_pause.png"}}‘);
$(".playButton").show();
}
})
原文地址:http://blog.51cto.com/12390959/2082196
时间: 2024-10-29 04:43:50