Mozilla サポートの検索

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

詳しく学ぶ

このスレッドはアーカイブに保管されました。 必要であれば新たに質問してください。

flash embed tag does not obey percentage size, even with html and body at 100%

  • 2 件の返信
  • 25 人がこの問題に困っています
  • 3 回表示
  • 最後の返信者: nutria

more options

For some reason i cannot get this swf file to show at 90% width and height. i have tried adding a style sheet in the header to explicity set the html and body to 100% but this still does not help. can anyone see if there is a problem in the code?

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>
<head>
<title></title>
<style type="text/css">
html, body {
  	margin: 0; 
	padding: 0;
  	height: 100%;
	width: 100%;
}
</style>


</head>

<body>
<center>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="90%" height="90%" ID="Captivate1">
  <param name="movie" value="tutorial.swf">
  <param name="quality" value="high">
  <param name="menu" value="false">
  <param name="loop" value="0">
  <embed src='tutorial.swf' width='90%' height='90%'  quality='high' pluginspage='http://www.macromedia.com/go/getflashplayer' type='application/x-shockwave-flash'/>
</object>


<BR>
<p>
<align=center><a Href="javascript:window.close();">Close Window</a>
</p>

</center>


</body>
</html>
For some reason i cannot get this swf file to show at 90% width and height. i have tried adding a style sheet in the header to explicity set the html and body to 100% but this still does not help. can anyone see if there is a problem in the code? <pre><nowiki><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title></title> <style type="text/css"> html, body { margin: 0; padding: 0; height: 100%; width: 100%; } </style> </head> <body> <center> <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="90%" height="90%" ID="Captivate1"> <param name="movie" value="tutorial.swf"> <param name="quality" value="high"> <param name="menu" value="false"> <param name="loop" value="0"> <embed src='tutorial.swf' width='90%' height='90%' quality='high' pluginspage='http://www.macromedia.com/go/getflashplayer' type='application/x-shockwave-flash'/> </object> <BR> <p> <align=center><a Href="javascript:window.close();">Close Window</a> </p> </center> </body> </html></nowiki></pre>

この投稿は cor-el により に変更されました

選ばれた解決策

That may happen because of the <center> element that doesn't have a height and width specified. Remember to specify dimensions for all containers if you use percentages, otherwise you may end up with 90% of 0 or a default value.

この回答をすべて読む 👍 4

すべての返信 (2)

more options

選ばれた解決策

That may happen because of the <center> element that doesn't have a height and width specified. Remember to specify dimensions for all containers if you use percentages, otherwise you may end up with 90% of 0 or a default value.

この投稿は cor-el により に変更されました

more options

you are correct, thanks