Click to See Complete Forum and Search --> : max-height help


keefdesign
03-05-2009, 12:57 PM
can't get this to work. I want the max-height of a div to be set to 590px (the native size of a flash movie) so that if the window is smaller, it won't give scroll bars, but resize the flash movie. make sense? - it works with max-width, but for display purposes, max-height would be better - nothing I do will get this property to work. here is the code:

This works:
<html>
<body>
<div style="max-width:590px">
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http<cfif cgi.server_port eq '443'>s</cfif>://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="100%" height="100%" id="loader" align="top">
<param name="allowScriptAccess" value="sameDomain" />
<param name="movie" value="loader.swf" />
<param name="quality" value="best" />
<param name="scale" value="no Scale" />
<param name="bgcolor" value="000000" />
<param name="flashvars" value="eBook=<cfoutput>#thisSwf#</cfoutput>"/>
<embed src="loader.swf" quality="best" scale="no Scale" bgcolor="000000" width="100%" height="100%" name="loader" align="top" flashvars = "eBook=<cfoutput>#thisSwf#</cfoutput>" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
</object>
</div>
</body>
</html>

this doesn't:
<html>
<body>
<div style="max-height:590px">
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http<cfif cgi.server_port eq '443'>s</cfif>://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="100%" height="100%" id="loader" align="top">
<param name="allowScriptAccess" value="sameDomain" />
<param name="movie" value="loader.swf" />
<param name="quality" value="best" />
<param name="scale" value="no Scale" />
<param name="bgcolor" value="000000" />
<param name="flashvars" value="eBook=<cfoutput>#thisSwf#</cfoutput>"/>
<embed src="loader.swf" quality="best" scale="no Scale" bgcolor="000000" width="100%" height="100%" name="loader" align="top" flashvars = "eBook=<cfoutput>#thisSwf#</cfoutput>" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
</object>
</div>
</body>
</html>

keefdesign
03-05-2009, 01:24 PM
I may have solved the problem: when I set the height property to 100% and then the max-height to 590px - it worked. If there is anything else I need to be aware of when using heights, I appreciate any advice. Thanks.