0

I embedded a flash game on my site with Swfobject, I defined the dimension, but the game fit the container. How i can define the width (and the height) also as max width?

<!-- Game embedding -->
<script type="text/javascript">
    var attributes = {id: "gm", name: "Rebuild Chile"};
    swfobject.embedSWF("game.swf", "gm", "720", "480", "9.0", null, attributes);
</script>

<div id="gm"></div>
<!-- Game embedding -->

What id wrong?

4

1 回答 1

0

我这样解决了:

<!-- Game embedding -->
<script type="text/javascript">
    var attributes = {id: "gm", name: "Game name"};
    swfobject.embedSWF("game.swf", "gm", "720", "480", "9.0", null, attributes);
</script>

<div id="gm_container">
  <div id="gm" style="height:480; witdh=:720;">
  </div>  
</div>
<!-- Game embedding -->
于 2013-11-08T09:07:00.137 回答