Topic: transparent png for background image?

So there is a lot of talk about the transparency code not working correctly in IE, but what if you set the background image to be a transparent png file to trick IE? However I played around for a while trying to add the line of code and couldn't figure it out. I deleted the background color code, but nothing works.

Suggestions?

Thanks
Bob
----------
www IdeaAttic com

Re: transparent png for background image?

Are you trying to make the flash transparent? If so try params.wmode = 'transparent'; in the gallery index.hml file. See example below using swfobject.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http&#58;//www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http&#58;//www.w3.org/1999/xhtml" xml&#58;lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Your Simpleviewer Gallery</title>
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript"> 
            var flashvars = &#123;&#125;;
            flashvars.firstImageIndex = "0";
            var params = &#123;&#125;;
            params.play = "true";
            params.menu = "false";
            params.quality = "best";
            params.scale = "noscale";
            params.wmode = "transparent";
            params.allowfullscreen = "false";
            params.allowScriptAccess = "sameDomain";
            params.swLiveConnect = "true";
            var attributes = &#123;&#125;;
            attributes.id = "galleryContent";
            swfobject.embedSWF&#40;"yourgalleries.swf", "galleryContent", "880", "560", "8.0.0", false, flashvars, params, attributes&#41;;
</script>
<style type="text/css" media="screen">
    object &#123; outline&#58;none; &#125;
</style>
</head>
<body>
<div id="galleryContent">
    <p>In order to view these galleries you must have <a href="http&#58;//www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash">Adobe Flash Player</a> installed. 
    If you know that you have Flash installed, then please ensure JavaScript and/or Active Content are enabled.</p>
</div>
</body>
</html>
Mike Richards
SimpleViewer Support Team.

Re: transparent png for background image?

Are you trying to make the flash transparent? If so try params.wmode = 'transparent'; in the gallery index.hml file. See example below using swfobject.

I understand the parms code, the problem is it wont work correctly in IE, my question was if a work around using a png file would "trick" the browser. However, since posting the question, I just modified the xml to over ride the background. See www IdeaAttic com for example.

Re: transparent png for background image?

wmode is working for me in IE, according to Adobe wmode is an available parameter in Internet Explorer 4.0 and higher.  What IE6 or below can't handle is alpha transparencies which things like PNGs use.  I'm basically using the code I showed above, just make sure you take out any background image in the flash obviously and it should work fine.  You can take a look at my gallery to see it in action.

Mike Richards
SimpleViewer Support Team.