WebMW
WebMW

Reputation: 524

IE9 Fails to load Flash (using AS 2.0) on "SOME" refreshes

What is the problem?
Internet Explorer 9 (both local and on the web) fails to load my flash banner on random refreshes. For instance, I just fully reloaded the page 19 times, and the 19th time the banner loaded. If I use Force Refreshes (CTRL+F5) OR clear the cache completely (even manually dumping the Temporary Internet Files directory), it does NO GOOD in fixing the situation. That leads me to believe it is not a cache issue. Both Firefox & Chrome always load it flawlessly, but I need this to work in IE because the website will be for that audience primarily.

How am I exporting this flash file and embedding it?
I am using a Flash banner using Flash CS5, exporting the .swf as Flash Player 8 / Actionscript 2.0.

I have embedded the flash as Dreamweaver CS5 does on default, but added an alternate (image) if the flash player is absent or earlier than Flash Player 6. Here is the embed code:

<object id="FlashID" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="778" height="313" title="title">
    <param name="movie" value="file.swf" />
    <param name="quality" value="high" />
    <param name="wmode" value="transparent" />
    <param name="swfversion" value="6.0.65.0" />
    <!-- This param tag prompts users with Flash Player 6.0 r65 and higher to download the latest version of Flash Player. Delete it if you don’t want users to see the prompt. -->
    <param name="expressinstall" value="Scripts/expressInstall.swf" />
    <!-- Next object tag is for non-IE browsers. So hide it from IE using IECC. -->
    <!--[if !IE]>-->
    <object type="application/x-shockwave-flash" data="file.swf" width="778" height="313" title="title">
      <!--<![endif]-->
      <param name="quality" value="high" />
      <param name="wmode" value="transparent" />
      <param name="swfversion" value="6.0.65.0" />
      <param name="expressinstall" value="Scripts/expressInstall.swf" />
      <!-- The browser displays the following alternative content for users with Flash Player 6.0 and older. -->
      <div class="alternative_logo">&nbsp;</div>
      <!--[if !IE]>-->
    </object>
    <!--<![endif]-->
  </object>

I will be SO GRATEFUL if someone can help me fix this. Thank you for your time.

Upvotes: 1

Views: 2717

Answers (1)

John Himmelman
John Himmelman

Reputation: 22000

You should consider using swfobject to embed SWFs. It handles various browser quirks nicely.

Example taken from Official Documentation:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
  <head>
    <title>SWFObject - step 3</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <script type="text/javascript" src="swfobject.js"></script>

    <script type="text/javascript">
    swfobject.registerObject("myId", "9.0.115", "expressInstall.swf");
    </script>

  </head>
  <body>
    <div>

      <object id="myId" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="780" height="420">

        <param name="movie" value="myContent.swf" />
        <!--[if !IE]>-->
        <object type="application/x-shockwave-flash" data="myContent.swf" width="780" height="420">
        <!--<![endif]-->
          <p>Alternative content</p>
        <!--[if !IE]>-->
        </object>
        <!--<![endif]-->
      </object>
    </div>
  </body>
</html>

Upvotes: 1

Related Questions