2012-08-03 33 views
1

如何重定向onclicking視頻幀的任何地方的頁面上任何地方的URL linkpage應該打開如何重定向頁面onclicking視頻幀的網址linkpage應該打開

CODE:

$(document).ready(function(){ 

       $("#ytplayer").attr('src', 'http://www.youtube.com/embed/' + getValue("id") +'?autoplay=1&origin=http://example.com'); 
    $("#back").click(function(){ 

       if(getValue("Animat")==1 || getValue("Animat")==2 || getValue("Animat")==3 || getValue("Animat")==4) 
       { 
     window.location.href = "Week-Animations.html?Animat=" + getValue("Animat") + "&week=" + getValue("week") + "&tier=" + getValue("tier"); 
       }});}); 

<iframe id="f" width="300" height="320" src=" " frameborder="0" allowfullscreen></iframe> 
    </div> 

回答

0

嘗試使用'start'參數作爲嵌入視頻的網址,這應該可以做到。

https://developers.google.com/youtube/player_parameters#start

所以,你需要做的是,當用戶點擊一個按鈕,改變視頻的網址添加一個「開始=時間」,時間是一個數字(可以使用34m10s去34分鐘,10秒)。讓我知道這是否有幫助。

乾杯伴侶,

鮑勃

相關問題