1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to center entire page?

Discussion in 'Web Design' started by iliketurtles, Jun 29, 2011.

  1. iliketurtles

    iliketurtles Regular Member

    Joined:
    Dec 10, 2008
    Messages:
    283
    Likes Received:
    10
    Home Page:
    I`ve got a brand new site, and I try to set it up so that the entire site is centered. How do I do that?

    Here`s the site: http://datagjenoppretting.net/
     
  2. akashvedi

    akashvedi Newbie

    Joined:
    Jan 9, 2010
    Messages:
    27
    Likes Received:
    2
    Home Page:
    Yeah i am looking for it's answer...
     
  3. SeRf*X

    SeRf*X Registered Member

    Joined:
    Apr 5, 2011
    Messages:
    59
    Likes Received:
    12
    what kind of web platform is this....or is it normal html?
     
  4. salsabot

    salsabot Junior Member

    Joined:
    Aug 30, 2010
    Messages:
    135
    Likes Received:
    17
    HTML:

    <div id="wrapper"> YOUR SITE HERE </div>

    CSS:

    #wrapper { width:1000px; 0 auto; }
     
  5. iliketurtles

    iliketurtles Regular Member

    Joined:
    Dec 10, 2008
    Messages:
    283
    Likes Received:
    10
    Home Page:
    @ SeRf*X: WP

    @ salsabot: Does it matter where I put the wrapper? In the beginning of the css?

    Will .main {width:1000px;} interfere with the wrapper?


    Edit: One more thing - it's been months since I did this kind of thing, so I seem to have forgotten everything I knew about coding.. How do I remove the underline where it says "Forside", in the sidebar to the left?
     
    Last edited: Jun 29, 2011
  6. HeXeR

    HeXeR Junior Member

    Joined:
    Dec 30, 2007
    Messages:
    121
    Likes Received:
    15
    Occupation:
    Self-employed
    Location:
    EU
    Home Page:
    <div class="main" style="margin:0 auto;">

    If you have everything in <div class="main">
     
  7. stgermain

    stgermain Junior Member

    Joined:
    Apr 29, 2011
    Messages:
    122
    Likes Received:
    24
    Home Page:
    I always put it in an outer table that is 100% width and height, and is centered.