A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: [CS3] Help centering swf vertically in browser

  1. #1
    Member
    Join Date
    Apr 2008
    Posts
    32

    [CS3] Help centering swf vertically in browser

    I have a swf file that is 1015 x 600 pixels. It looks beautiful at 1024 x 768 but at 1280 x 1024 it floats. Is there a way that I can use HTML of JavaScript to center the swf vertically?

    Thanks

  2. #2
    The easiest way is:

    <div style="position:fixed; top:0; left:0; width:100%; height:100%;">
    <div style="height:100%; display:table; margin:0 auto;">
    <div style="vertical-align:middle; display:table-cell;">

    <div>

    Your flash content....


    </div>
    </div>
    </div>



    Scotty does know how to Fla-make cool ads.

    http://flamake.net - this Ads will Fla-make you crazy. Find your cheap flash banners and see the best commercials around the world.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center