這是在我的網站在YouTube嵌入代碼的例子:如何動態添加&autoplay = 1到youtube嵌入代碼?
<object width="525" height="320"><param name="wmode" value="opaque">
<param name="movie" value="http://www.youtube.com/v/yciTqWafKPU?version=3">
<param name="allowFullScreen" value="true">
<param name="allowscriptaccess" value="always">
<embed src="http://www.youtube.com/v/yciTqWafKPU?version=3" type="application/x-shockwave-flash" width="525" height="320" allowscriptaccess="always" allowfullscreen="true" wmode="opaque">
</object>
我相信我需要添加&autoplay=1
到這一點:<param name="movie" value="http://www.youtube.com/v/yciTqWafKPU?version=3&autoplay=1">
這:<embed src="http://www.youtube.com/v/yciTqWafKPU?version=3&autoplay=1" type="application/x-shockwave-flash" width="525" height="320" allowscriptaccess="always" allowfullscreen="true" wmode="opaque">
我需要用jQuery動態地做到這一點。我將如何做到這一點?
嗯我似乎無法得到這個工作,出於某種原因... – 2011-05-26 21:13:38
'未捕獲TypeError:對象[對象對象]沒有方法'prop'' – 2011-05-26 21:19:53
'.attr'而不是'.prop'作品 – 2011-05-26 21:29:29