How to display Javascript on top of Flash
Posted under Web Design Blog | Share this on Yahoo MessengerDigg this Post | Sphinn this Post | Add to Delicious | Add to Technorati | Add to Propeller
Ever had that experience where your javascript is shown behind your flash file? Take a look at this example problem:
Having this problem is such an annoyance for webdesigners since this greatly affects the overall design of the site. So I did a search how to solve this problem. Here is what you need to add on your html embed code.
<param name=”wmode” value=”transparent”>
and
<embed wmode=”transparent” src=”flash.swf”>
Update: October 31,2007
if you are using, AC_FL_RunContent, add this
<script type=”text/javascript”>
AC_FL_RunContent( ‘codebase’,'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0′,’width’,'1000′,’height’,'650′,’src’,'catalogue’,'quality’,'high’,'pluginspage’,'http://www.macromedia.com/go/getflashplayer’,'movie’,'catalogue’,‘wmode’,'transparent’ ); //end AC code
</script>
After you’ve updated the file, it should look like this:
This fix works on both IE and Firefox, not sure if it’ll work with other browsers though. Hope this helps. Let me know if you have problems. Thanks.
Check my other posts:
- Say Yes to No!Spec - No to Speculative Work
- Understanding Royalty-Free Stock Photos
- Photoshop TV
- Understanding Copyright
Holly Says:
I can’t seem to get this to work in IE7, I even tried putting the Flash object and the JavaScript object in seperate DIVs and asigning a z-index to them, still no luck. Any suggestions? Thanks!
Alfredo Says:
Thanks Holly for the comment. I will try to test on IE7 and will update the post if I find a fix for this problem.
cxc Says:
on ie7 and firefox not worked … still flash on top …
—
ie7 ve firefox da ise yaramadi … flash hala ustte…
Alfredo Says:
cxc, whats the url?
cxc Says:
alfredo,
noting url … still designing pages but i found a solution for the problem here is a link;
http://blog.deconcept.com/swfobject
for demo;
http://www.property-magic.com/lightbox_over_flash.html