A Flash Developer Resource Site

Page 1 of 2 12 LastLast
Results 1 to 20 of 24

Thread: [RESOLVED] How to center...

  1. #1
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348

    [RESOLVED] How to center...

    Maybe I should have titled this...
    Save me from going insane.
    Or about to jump off the bridge....

    Anywho... The .swf file stays centered to the back ground in the amazing
    INTERNETS EXPLORERRERERERERR

    But in mozilla... The flash centers very differently...


    Basically.. I want it to look like it does in internet exploder in all browsers.


    http://www.mentaldeficit.com/Test/index.html

    And yes... the back ground image is large and horrid. So sorry to hurt your eyes.
    Of all the things to get frustrated with.... I choose webdesign.... sigh


    mike nio weirdo .....whatever you want to call me
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  2. #2
    Senior Member catbert303's Avatar
    Join Date
    Aug 2001
    Location
    uk
    Posts
    11,222
    Hi,

    The linked page looks the same for me in IE 6, Firefox 2 and Opera 9. I can try IE 7 and Safari when I'm home from work. Do you have a screenshot showing the differences you're seeing?

  3. #3
    Junior Member
    Join Date
    Mar 2007
    Posts
    21
    looks the same in FF and IE here too.

  4. #4
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    Hehe... I forgot to mention...
    In firefox when you resize the browser the flash content sort of moves out of the designated area. But In internet explorer it seems to stay where it should.

    Hopefully that clears some things up







    This is my 1337 post (wahoooo)
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  5. #5
    Senior Member ihoss.com's Avatar
    Join Date
    Oct 2004
    Location
    Norway
    Posts
    581
    nope, works fine here. Its in the center no matter how I resize it.

  6. #6
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348

    Picture to help display what I mean.

    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  7. #7
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    Are you using an older version of Firefox? I just tried it in IE 7 and in Firefox and I see it the same as your IE screenshot in both browsers when I resize.
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  8. #8
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    I just checked for updates and it said I am up to date...
    hmmm
    I don't know what to think now...
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  9. #9
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    I just went check it again to see if I could see anything strange and the background image is missing now.
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  10. #10
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    Yeah I took it off last night. I put up a much smaller sized one (in kb).
    It is the same back ground I used in my example picture.
    Which i also too off.
    If you want that one back up just ask.

    Glad to see this mystery hasn't been given up on.
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  11. #11
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    =( I still haven't made any progress on this issue.
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  12. #12
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    When you had the blue background it was working for everyone correctly in both browsers but when you switched to the red it broke. What all did you change when you changed the background color. Also, is there a reason that you are using Flash to display your text?
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  13. #13
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    I don't believe I changed anything in the code.
    I just deleted the last picture and uploaded a new one with the same name.
    I have flash there because I was going to make the website in it.
    Let me change up the flash content inside.. right now the .swf is 800px and the BG content area is only like 600.
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  14. #14
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    Ok I changed it.
    It is now a gray square as the flash movie to show the content area.
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  15. #15
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    Just for some added stuffs.

    www.webagent007.com pulls off the same thing. Except it works in my browser.
    Why my own site doesn't. Is beyond me.
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  16. #16
    Senior Member
    Join Date
    May 2007
    Posts
    266
    Put your object code inside a div. Remove the <center> tag.
    <div id="movie">
    <OBJECT classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000"
    codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
    WIDTH="550" HEIGHT="600" id="splash" ALIGN="top">

    <PARAM NAME=movie VALUE="splash.swf">
    <PARAM NAME=quality VALUE=best>
    <PARAM NAME=scale VALUE=noscale>
    <PARAM NAME=salign VALUE=T>
    <PARAM NAME=wmode VALUE=transparent>
    <PARAM NAME=bgcolor VALUE=#000000>

    <EMBED src="splash.swf" quality=best scale=noscale salign=T wmode=transparent bgcolor=#000000 WIDTH="550" HEIGHT="600" NAME="splash" ALIGN="top"
    TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">
    </EMBED>
    </div>
    Then set the margins with css
    div#movie {margin:0 auto; width:550px; height:600px; }

    also set the default margins with

    *, html {margin:0; padding:0;}
    This will put the flash in the exact center of the page irregardless of the monitor size or resolution.

  17. #17
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    Hmmm... for me atleast. It still moves off of the center of the background as I minimize the window to sizes smaller than the width of the movie
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  18. #18
    Mental Deficit Nionicle's Avatar
    Join Date
    Mar 2002
    Location
    Utah, Hyrum
    Posts
    1,348
    Officialy RESOLVED WAHOOOO

    Thanks to Jasonsplace

    Code:
    <html>
    
    <head>
    
    <title>Mental Deficit-A personal portfolio of Michael Abernathy</title>
    
    </head>
    
    <style type="text/css">
    
    	body {
    		margin: 0px 0px 0px 0px;
    		padding: 0px;
    		background-color: #000000;
    		}
    	.content{
    		background-image: url(BasicBG.jpg);
    		background-repeat: repeat;
    		background-position: center top;
    		width: 100%;
    		height: 1000px;
    		}
    
    </style>
    
    <body>
    <table border="0" cellpadding="0" cellspacing="0" class="content">
    <tr>
    <td>&nbsp;</td>
    <td width="550" valign="top">
    
    <OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
     codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
     WIDTH="550" HEIGHT="600" id="splash" ALIGN="top">
    
     <PARAM NAME=movie VALUE="splash.swf">
     <PARAM NAME=quality VALUE=best>
     <PARAM NAME=scale VALUE=noscale>
     <PARAM NAME=salign VALUE=T>
     <PARAM NAME=wmode VALUE=transparent>
     <PARAM NAME=bgcolor VALUE=#000000>
    
     <EMBED src="splash.swf" quality=best scale=noscale salign=T wmode=transparent bgcolor=#000000  WIDTH="550" HEIGHT="600" NAME="splash" ALIGN="top"
     TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">
    
    </EMBED>
    
    </OBJECT>
    </td>
    <td>&nbsp;</td>
    </tr>
    </table>
    
    </body>
    
    </html>
    I can only postulate the probability of performing at a paramount level of perfection praised by the pulchritudinous paragon whose only practice is to preserve such a paradigm.

  19. #19
    Senior Member ihoss.com's Avatar
    Join Date
    Oct 2004
    Location
    Norway
    Posts
    581
    sticks way is better. The only thing he forgot to mention is that you need position: relative in there as well:

    Code:
    div#movie {margin:0 auto; width:550px; height:600px; position: relative;}
    
    also set the default margins with
    
    *, html {margin:0; padding:0;}

  20. #20
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    Why is sticks way better? Doing things in all CSS may be a newer way of doing things but table layouts are tried and true. They've worked for years and continue to do so in all browsers equally. CSS is nice and all but sometimes it is a major pain in the neck when you want something to look the same in IE and Firefox and Opera and Safari and every other browser that your users may be using.
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

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