• incredibledad

    (@incredibledad)


    Hi there,

    I’ve searched the relevant posts here and googled away but can’t solve how to center my wrapper at https://www.incredibledad.com.

    Here’s the relevant code in my style.css

    * {
    margin: 0; padding: 0;
    }
    body {
    text-align: center;
    font: 12px Verdana, Arial, Helvetica, sans-serif;
    color: #666;
    background: #FF881A url(images/grey_bg.gif) repeat-x 0 0;
    }
    #all {
    width: 935px;
    margin: auto auto;
    text-align: left;
    }
    a {
    color: #900;
    text-decoration: none;
    }
    a:hover {
    color: #cc0000;
    }
    img {
    border:0;
    }
    .break {
    font-size: 0;
    width: 0; height: 0;
    clear: both;
    }
    .alignleft {
    float: left;
    margin: 4px 10px 5px 0;
    }
    .alignright {
    float: right;
    margin: 4px 0 5px 10px;
    }
    .aligncenter {
    text-align: center;
    }
    .hidden {
    display: none;

    }
    li{
    list-style: none;
    }

    h1 {font-size: 18pt; padding: 10px 0; font-family:Arial, Helvetica, sans-serif; color:#000000;}
    h3 {font-size: 10pt;padding: 10px 0;font-family:Arial, Helvetica, sans-serif; color:#000000;}
    h4, h5, h6 {font-size: 9pt;padding: 10px 0;font-family:Arial, Helvetica, sans-serif; color:#000000;}

    .aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
    }

    .alignleft {
    float: left;
    }

    .alignright {
    float: right;
    }

    /** BEGIN wrapper **/

    #wrapper {
    width: 935px;
    margin: auto auto;
    text-align: left;
    border:3px solid #333;
    background-color:#FFFFFF;
    margin-top:20px;
    }
    /** END wrapper **/

    Help please!

    Many thanks in advance!

    ID

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter incredibledad

    (@incredibledad)

    Hi members,

    Second call for help please? Many thanks in advance.

    ID

    jrav001

    (@jrav001)

    It looks centered to me…both IE8 and Firefox.

    Thread Starter incredibledad

    (@incredibledad)

    It’s a touch off to the right (more pronounced if I increase the border).

    Thanks for responding and look forward to any assistance on the code.

    ID

    Michael

    (@alchymyth)

    exactly the border is the reason – the border width is added to the width of the div #wrapper.
    if you want balance with a 3px border, you could add the 6px to the width of the id #all and make it 941px wide.

    Thread Starter incredibledad

    (@incredibledad)

    Beautiful, problem solved.

    Many thanks achymyth!!!

    ID

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Centering Wrapper’ is closed to new replies.