Bleeding Flash has been a nightmare today.

Why can’t it ever be simple!! Today’s specific problem was that a trailer that worked fine standalone broke in either IE or Firefox, dependent on how I integrated it.

I’m sure it must be something withing the flash file (or possible withing some javascript, although I couldn’t see *anything* that could possibly affect it in my javascript).

The problem was that in firefox the flash movie would only play if you moved your mouse!!

“WHAT?!” I hear you yell!

After some investigation, I found that the embed method worked fine in Internet explorer, yet not in firefox, whereas the the flash satay method worked fine in firefox but not IE…

After a hell of a lot of experimenting I had to do just what I didn’t want to, and use conditional comments to determine which method to use. Bad idea, but the only way I could get round it… for now…

This is the code, line breaks marked » (in case anyone knows an easier, tidier fix!):

<![if !IE]> <object type=”application/x-shockwave-flash” data=”swf/movie.swf” width=”320″ height=”240″> <param name=”movie” value=”swf/movie.swf” /> <param name=”wmode” value=”transparent” /> <param name=”allowScriptAcess” value=”sameDomain” /> <param name=”autostart” value=”true” /> <param name=”controller” value=”true” /> </object>
<![endif]>

<!–[if IE]>\r\n
<div id=”video”> <object
classid=”clsid:d27cdb6e-ae6d-11cf-96b8-444553540000″ codebase=”http://fpdownload.macromedia.com/pub/ »
shockwave/cabs/flash/swflash.cab#version=8,0,0,0″ width=”320″ height=”240″ id=”trailer”> <param name=movie value=”swf/movie.swf”> <param name=quality value=high> <param name=bgcolor value=#000000> <embed src=”swf/movie.swf” quality=high bgcolor=#000000width=”320″ height=”240″ name=”trailer” align=”” type=”application/x-shockwave-flash”
pluginspage=”http://www.macromedia.com/go/getflashplayer”> </embed>
</object> </div>
<!enfif]–>