PDA

View Full Version : limit flash object to parent div



dschmitz
21 Apr 2011, 04:29 AM
hello,

my flash object (embedding it with swfobj) should be shown only partially, within the limits of parent div. but i didn't manage to limit its size to the parent size, it still shows up larger. i tried transparent and opaque modes, with no luck. any ideas how to fix it?

as you see, the height of swf is 768px, but it needs to be displayed only as 500px


<div id="inner" style=" height:500px; width:984px; margin-top:-134px; padding:0; border:0;">
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="984" height="768" id="myFlashContent" align="middle">
<param name="movie" value="flash.swf" />
<param name="wmode" value="opaque" />
<!--[if !IE]>-->
<object type="application/x-shockwave-flash" data="flash.swf" width="984" height="768" align="middle">
<param name="wmode" value="opaque" />
<!--<![endif]-->
<a href="http://www.adobe.com/go/getflashplayer">
<img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" />
</a>
<!--[if !IE]>-->
</object>
<!--<![endif]-->
</object>
</div>

lisahill
21 Apr 2011, 07:20 AM
The page is "auto generated" to contain a DIV tag containing a Flash plugin object.
The DIV tag has no name/ID property attached.

Looks something like this:<div class='someClass'>

<OBJECT CLASSID='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' WIDTH=136 HEIGHT=93>
<PARAM NAME=MOVIE VALUE=http//www.GypsyTrader.com/myFlash.swf>
<PARAM NAME=PLAY VALUE=TRUE>
<PARAM NAME=LOOP VALUE=TRUE>
<PARAM NAME=QUALITY VALUE=HIGH>
<EMBED SRC=http//www.GypsyTrader.com/myFlash.swf WIDTH=136 HEIGHT=93
PLAY=TRUE LOOP=TRUE QUALITY=HIGH>
</EMBED>
</OBJECT>

</div>
How can I find the DIV's object reference?
For example, maybe find the Flash object and then it's parent container DIV?
Something like that...

I do not know where to start.

Thanks,

[deleted by mod :: new users aren't allowed links/signatures]