$(document).ready(function() {
var clone = $("#me_flash_0").clone(true);
if($('video').attr('class') == "pause_0"){
$("#me_flash_0").remove();
}
$('.top_item img').click(function(){
$("#me_flash_0_container").html(clone);
$(this).hide();
});
}
#me-flash_0
是一個<embed>
元素。而#me_flash_0_container
是包裝容器。問題是克隆的對象似乎是空的。 html(clone)
沒有效果。克隆並插入jQuery
Firebug不顯示任何錯誤。
下面是相關的HTML
<div id="me_flash_0_container" class="me-plugin">
<embed id="me_flash_0">
</div>
<video class="pause_199" width="586px" height="440" src="some link" autoplay="true" tabindex="0" style="display: none;"></video>
任何想法?
這似乎是要走的路!謝謝。 – 2012-07-16 17:51:03