A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: How to center align the whole page?

  1. #1
    Member
    Join Date
    Nov 2005
    Posts
    38

    How to center align the whole page?

    hi

    i fixed the the units of the site with px. and i exported from flash as centered page.but when i open it in the browser its on the left side,and its not in the center.

    how can I align the whole page in center please?
    i tryed some CSS scripts but none worked:



    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>.....Anna Filipova.....</title>
    <script language="javascript">AC_FL_RunContent = 0;</script>
    <script src="AC_RunActiveContent.js" language="javascript"></script>
    </head>
    <link rel="shortcut icon" href="favicon.ico" type="image/x-icon" />
    <body bgcolor="#000000">
    .centered {
    /*position: absolute;*/
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: 50%;
    height: 50%;
    margin: auto;
    }
    <!--url's used in the movie-->
    <!--text used in the movie-->
    <!--

    -->

    <!-- saved from url=(0013)about:internet -->
    <script language="javascript">
    if (AC_FL_RunContent == 0) {
    alert("This page requires AC_RunActiveContent.js.");
    } else {
    AC_FL_RunContent(
    'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0',
    'width', '766',
    'height', '750',
    'src', 'index',
    'quality', 'high',
    'pluginspage', 'http://www.macromedia.com/go/getflashplayer',
    'align', 'middle',
    'play', 'true',
    'loop', 'true',
    'scale', 'noscale',
    'wmode', 'window',
    'devicefont', 'false',
    'id', 'index',
    'bgcolor', '#000000',
    'name', 'index',
    'menu', 'true',
    'allowFullScreen', 'false',
    'allowScriptAccess','sameDomain',
    'movie', 'index',
    'salign', ''
    ); //end AC code
    }
    </script>
    <noscript>
    <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="766" height="750" id="index" align="middle">
    <param name="allowScriptAccess" value="sameDomain" />
    <param name="allowFullScreen" value="false" />
    <param name="movie" value="index.swf" /><param name="quality" value="high" /><param name="scale" value="noscale" /><param name="bgcolor" value="#000000" /> <embed src="index.swf" quality="high" scale="noscale" bgcolor="#000000" width="766" height="750" name="index" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
    </object>
    </noscript>
    </body>
    </html>


    Could you please help me to correct what is wrong?thank you

  2. #2
    Senior Member EQFlash's Avatar
    Join Date
    Jun 2002
    Location
    where i'm at
    Posts
    2,735
    in the html file that you have above, put this tag - <center> right above this line
    PHP Code:
    <!-- saved from url=(0013)about:internet --> 
    and this tag - </center> right next to the </noscript> tag at the bottom.
    this centers the flash into the html. NOTE: everytime you publish the flash file, it overwrite these new tags. to fix this, in File>Publish Settings, on the format tab uncheck the html box for the flash file so that the html will not be overwritten everytime you edit, and publish the swf file. HTH
    Last edited by EQFlash; 05-20-2008 at 05:19 PM.

  3. #3
    Member
    Join Date
    Nov 2005
    Posts
    38
    thanks man,u r great

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