0

I have a video that I would like to open in fullscreen on click of the thumbnail. Following is my code

<a href="#videoDiv" data-rel="popup"> 
    <img src="imageThumbnail.jpg" onClick="selectVideo(1)" >
</a>
<div id="videoDiv" data-role="popup"class="ui-content"></div>

 function selectVideo(id) {
   var videolist = getvideos()[id];
   if (videolist) {
    se$("#videoDiv").html(videolist.url);
   }
 }

The videolist.url returns an string like this

<iframe width="640" height="360" src="http://www.youtube.com/embed/hVfYVNALIS0?autoplay=1&amp;rel=0" frameborder="0" allowfullscreen=""></iframe>

How can I make the video play fullscreen directly when clicked on thumbnail? Thanks

jsp
  • 2,546
  • 5
  • 36
  • 63

0 Answers0