2011-05-08 45 views
0

我爲自己的網站構建了一些Flash內容,但我需要一些div才能在Flash的頂部顯​​示。我讀過使WMODE = transparent應該可以工作,但我在確定需要將它放在我的代碼中的位置時遇到了一些麻煩。允許div在flash內容之上分層

首先,這是正確的嗎?應該讓WMODE =透明幫助我將我的div覆蓋在頂部?第二...

有人可以解釋,如果我有param name =「wmode」value =「transparent」在這個代碼的正確位置或沒有其他的東西需要這個工作嗎?

<script type="text/javascript"> 
AC_FL_RunContent('codebase','http://download.macromedia.com/pub/shockwave/cabs/flash 
/swflash.cab#version=9,0,28,0','width','680','height','370','src','slideshow- 
load','quality','high','pluginspage','http://www.adobe.com/shockwave/download 
/download.cgi?P1_Prod_Version=ShockwaveFlash','movie','slideshow-load'); //end AC code 

</script><noscript> 
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" 
width="680" height="370"> 
    <param name="wmode" value="transparent"> 
    <param name="movie" value="slideshow-load.swf" /> 
    <param name="quality" value="high" /> 
    <embed src="slideshow-load.swf" quality="high" pluginspage="http://www.adobe.com/shockwave 
/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" 
width="680" height="370"></embed> 
    </object> 
</noscript> 

任何幫助,非常感謝。

回答

1

好的,我修好了!

我將Flash作爲HTML文件發佈,窗口模式設置爲透明(在Flash中),然後將代碼從自動創建的文件直接複製到我的文件中,效果很好。如果任何人有興趣,這是代碼。

<script language="javascript"> 
if (AC_FL_RunContent == 0) { 
    alert("This page requires AC_RunActiveContent.js."); 
} else { 
    AC_FL_RunContent(
     'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0', 
     'width', '680', 
     'height', '370', 
     'src', 'index-slideshow', 
     'quality', 'high', 
     'pluginspage', 'http://www.macromedia.com/go/getflashplayer', 
     'align', 'middle', 
     'play', 'true', 
     'loop', 'true', 
     'scale', 'showall', 
     'wmode', 'transparent', 
     'devicefont', 'false', 
     'id', 'index-slideshow', 
     'bgcolor', '#000000', 
     'name', 'index-slideshow', 
     'menu', 'true', 
     'allowFullScreen', 'false', 
     'allowScriptAccess','sameDomain', 
     'movie', 'index-slideshow', 
     'salign', '' 
     ); //end AC code 
} 
</script> 
<noscript> 
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="680" height="370" id="index-slideshow" align="middle"> 
<param name="allowScriptAccess" value="sameDomain" /> 
<param name="allowFullScreen" value="false" /> 
<param name="movie" value="index-slideshow.swf" /><param name="quality" value="high" /><param name="wmode" value="transparent" /><param name="bgcolor" value="#000000" /> <embed src="index-slideshow.swf" quality="high" wmode="transparent" bgcolor="#000000" width="680" height="370" name="index-slideshow" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" /> 
</object> 
</noscript> 

恐慌:)