Hi Larry. re: docs - Documentation which explains all the params etc is of course available, and is linked to from the project home page: http://code.google.com/p/swfobject/wiki/documentation
having a read of the API: http://code.google.com/p/swfobject/wiki/api and the FAQ: http://code.google.com/p/swfobject/wiki/faq is also useful. re: attributes - You do not need to set the id or name attributes unless you want it changed from the target div you specify in your embedSWF() call. By default, your new <object> will inherit the target's id. The only time the attribute params need to be set is if you are doing flash < > browser communications through the ExternalInterface classes. re: layout - As SWFObject 2.x OVERWRITES the target <div> with the swf <object> tag, you will want to apply your stying to a wrapper div in order to ensure the styling remains after the <div> is overwritten. You would want something like the below ... <div id="Background"> <div id="flashtargetdiv> alt content here. This is the div SWFObject will replace with an object tag. </div> </div> ... Also, if you Flash content is BEHIND all of your other content, then your wmode should = "opaque", not "transparent" (as you are not needing to show anything through the Flash file). This will lessen CPU usage etc. Cheers, Aran SWFObject 2.x replaces the target div On Wed, May 5, 2010 at 1:06 PM, Larry <[email protected]> wrote: > I'm not grokking swfobject 2.0 at all. I have a flash movie I want to > be the background, and my content on top of it. An example of what I > want using the old swfobject and no master pages is at > http://www.rainbowandwish.com. > If you look at this website I have scrolling text in the center. > That's not showing at all with the below code. > > What I'm getting with the new swfobject is the content either on top, > then the flash, or the flash and then the content at the bottom. > > Also, nowhere is it explained how you come up with the id and name > attributes, so I just made something up. And, is there any > documentation of ALL the possible param, attribute, and flashvars > possibilities, with explanations? > > Here's my real simple code so far: > > <html xmlns="http://www.w3.org/1999/xhtml"> > <head runat="server"> > <title>Untitled Page</title> > <asp:ContentPlaceHolder id="head" runat="server"> > </asp:ContentPlaceHolder> > <link type="text/css" rel="stylesheet" href="~/CSS/Styles.css" /> > <script type="text/javascript" src="Javascript/swfobject.js"></ > script> > > <script type="text/javascript"> > var flashvars = {}; > var params = {}; > params.menu = "false"; > params.wmode = "transparent"; > params.allowfullscreen = "false"; > var attributes = {}; > attributes.id = "BackgroundFlash"; > attributes.name = "BackgroundFlash"; > > swfobject.embedSWF("RainbowWishBackgroundText.swf", > "Background", "100%", "860", "9.0.0", "expressInstall.swf", flashvars, > params, attributes); > </script> > > </head> > <body> > <form id="form1" runat="server"> > <div> > <asp:Label ID="lblTest" runat="server" Text="HELLO WORLD"></ > asp:Label> > > <div> > <asp:ContentPlaceHolder id="cntBody" runat="server"> > > </asp:ContentPlaceHolder> > </div> > <div id="Background"></div> > </div> > </form> > </body> > </html> > > #Background is defined in my style sheet as: > > #Background > { > position: absolute; > top: 0px; > left: 0px; > width: 100%; > height: 870px; > border-style: none; > margin: 0px; > padding: 0px; > text-align: center; > } > > > Thanks!!! > > -- > You received this message because you are subscribed to the Google Groups > "SWFObject" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<swfobject%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/swfobject?hl=en. > > -- You received this message because you are subscribed to the Google Groups "SWFObject" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/swfobject?hl=en.
