1 (edited by Rador8 2011-02-27 15:55)

Topic: IE7 - link to a SWF file - height 100%

Hello wink

I have a Web site where I have the game "Snake" for Nokia mobile phones in a SWF file.

With Firefox and Opera, I can play the game by a direct link to the SWF file.

But with Internet Explorer 7, it is no more possible to view drectly a SWF file !

So, I made a little HTML page where I insert the SWF file. I want the game as big as the screen of the player so I write 100% for width and height.

<p>
  <object type="application/x-shockwave-flash" data="serpent.swf" width="100%" height="100%">
  <param name="movie" value="serpent.swf"></object></p>

The problem is that Firefox and Opera do not understant 100% for height ! It should be OK if I write a number (e.g. 600) and not a %. But in this case, the height is not always as big as the screen of the visitor !

Do you have a solution ?

Re: IE7 - link to a SWF file - height 100%

You can try using JavaScript. The innerWindow property or something like that...

Re: IE7 - link to a SWF file - height 100%

A friend gives me a good solution :

<!--[if IE]>
  <a href="serpent.htm">Jouez au serpent</a> -
<![endif]-->

<!--[if !IE]> <-->
  <a href="serpent.swf">Jouez au serpent</a> -
<!--> <![endif]-->

With this method, the link will be the HTML page for IE and the SWF page for other browsers !