Hi Ben,
As Nathan said applying your styling to a wrapper div will achieve greater
control across browser.
I also had to position with absolute - then I was able to adjust its
position with assuming that you intend to do this as half of the swf is
hidden outside the body
document.getElementById("flexApp").style.top = 0;
document.getElementById("flexApp").style.top = "50%";
hth - S
On 24 May 2010 16:23, Nathan Mynarcik <[email protected]> wrote:
> Put your div for the swf inside a wrapper div. Apply styling to position
> that wrapper where you want on the page.
>
>
> -----Original Message-----
> From: Ben H <[email protected]>
> Date: Mon, 24 May 2010 07:03:52
> To: SWFObject<[email protected]>
> Subject: [SWFObject] Trying to position my SWF using CSS top but it's not
> working at all?
>
> Hey guys,
>
> I'm trying to position my Flex app so that it's further down the page,
> but I can't get it working. It's still appearing in the top left. Here
> is the HTML, any help would be greatly appreciated!
>
> <html lang="en">
> <head>
> <title>Page</title>
> <style type="text/css">
> body { margin: 0px; overflow: hidden; }
> #swf {top:50%;}
> </style>
>
> <script src="http://ajax.googleapis.com/ajax/libs/swfobject/2.2/
> swfobject.js"></script>
> <script type="text/javascript">
> var flashVars = {
> testVar: "value"
> };
> var params = {
> allowFullScreen: "true",
> allowScriptAccess: "sameDomain"
> };
>
> swfobject.embedSWF( "link_to_the_swf", "swf", "100%", "100%",
> "10.0.0", "playerProductInstall.swf", flashVars, params );
> </script>
> </head>
> <body scroll="no">
>
> <div id="swf">
> <p>Alternative content</p>
> </div>
>
> </body>
> </html>
>
> --
> 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]<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.