Transparent flash files

Transparent flash files

By default a flash file is a solid rectangle that shows the content inside the flash file, normally you cannot see the html content behind it.

You can edit the the html code for the swf file and add a parameter called "wmode" and set it's value to "transparent" then swf flash background becomes transparent and you can see the html content through the flash file.

By default html code of a flash file looks like this:

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/
swflash.cab#version=7,0,19,0" width="100" height="100">
<param name="movie" value="animation.swf" />
<param name="quality" value="high" />
<embed src="animation.swf" width="100" height="100" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/
x-shockwave-flash"></embed>
</object>

Here is how it should look with wmode=transparent:

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/
swflash.cab#version=7,0,19,0" width="100" height="100">
<param name="movie" value="animation.swf" />
<param name="quality" value="high" />
<param name="wmode" value="transparent" />
<embed src="animation.swf" width="100" height="100" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/
x-shockwave-flash" wmode="transparent"></embed>
</object>

 
normal flash file   transparent flash file

Note: The wmode is written in 2 locations inside the html code as you can see in html code above, first location is read by Internet Explorer type browsers and second locations is read by Mozilla type browsers.

Note: If windowless mode is used, performance can be affected to some degree. If fastest performance is a top priority, you may consider other design options.

Note: Some browsers cannot click a html link through the transparent flash file.


Share with Google Plus