How to change video source onclick?
问题 HTML: <div class="source" id="source_one" onclick="chnageToSourceTwo()"> Source 1 </div> <video id="example_video_1" class="video-js vjs-default-skin vjs-big-play-centered" controls preload="none" width="640" height="360" poster="" data-setup="{}"> <source src="example_video_1.mp4" type='video/mp4' /> </video> Script: function chnageToSourceTwo() { document.getElementById("example_video_1").src="example_video_2.mp4"; } The video source is not changing after clicking on div. I am using the