Welcome to WebDesignForums.net!
You're currently viewing WDF as a guest. By registering for a free account, you'll be able to participate with other members in our friendly community. Being a member allows you to ask questions and get answers for those troublesome web development tasks!

In addition, as a member you'll be able to post your websites up for review. Using our unique website review system you can gain some amazing feedback from some of the best web developers around. This is a completely free service to all registered members.

Ready to register yet? Registration is 100% free. Click Here To Join Now!

how to make my website at center when zoom for all bowsers?

Discussion in 'HTML and CSS Help' started by hanywell, Jun 16, 2012.

  1. Offline

    hanywell New Member

    Message Count:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Gender:
    Male
    hi to all

    i face a problem in designing my website

    and the problem is
    my website is centered at natural view
    when i zoom out my website go to left

    this is a pic of my website when i zoom out till 10%

    the web site be @ this position

    web1.png
    and when i do that for cnn website and zoom out to 10% it still at center

    like in this pic

    web2.png
    and i try
    text-align at body tag and it didn't do any thing

    need ur help


  2. Offline

    TheGAME1264 The Displaced Web Redneck Moderator

    Message Count:
    9,382
    Likes Received:
    1,245
    Trophy Points:
    113
    Gender:
    Male
    Location:
    Not from USA
    Code:
    div#page-container {margin:  0px auto;  width:  (your width);}
    


  3. Offline

    hanywell New Member

    Message Count:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Gender:
    Male
    @ TheGAME1264 thank u for ur help


    and i have another problem

    how to make background didn't scroll with page

    i try background-attachment:fixed;

    but when zoom

    background still at center(V AND H) while page container go to center top(H only) at zoom out 10%


  4. Offline

    TheGAME1264 The Displaced Web Redneck Moderator

    Message Count:
    9,382
    Likes Received:
    1,245
    Trophy Points:
    113
    Gender:
    Male
    Location:
    Not from USA
    Code:
    body {
       background:  (your background) fixed top center no-repeat;
    }


  5. Offline

    m3n0tu18 WDF Moderator and Drupalite!

    Message Count:
    1,372
    Likes Received:
    248
    Trophy Points:
    63
    Gender:
    Male
    Location:
    New York
    OOOO Simple code answers. Pure genius! love it :D...Thinking about it.. That's not like you game lol!


  6. Offline

    TheGAME1264 The Displaced Web Redneck Moderator

    Message Count:
    9,382
    Likes Received:
    1,245
    Trophy Points:
    113
    Gender:
    Male
    Location:
    Not from USA
    It was a simple fix. Why make it complicated? It's like that Tupac guy in the Everest commercials...it's EASY!


    m3n0tu18 likes this.

Share This Page