Forums

Centering header (2 posts)

  1. samandasworld
    Member
    Posted 3 years ago #

    I put in a header and I can center it to save my life. Where or how can I center my header in this stylesheet? Thanks

    #topheader {
    background: url(http://www.giantesssex.com/image/giantessbanner2.jpg);
    background-repeat: no-repeat;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding: 0px;
    float: right;
    border-bottom: 1px solid #444;
    }

    #header{
    margin: 0 auto;

    I've tried so many things including auto, right, left nothing works, it always leans towards the left and won't move.

  2. alchymyth
    The Sweeper & Moderator
    Posted 3 years ago #

    try the following (define width and height; take out the float):

    #topheader {
    background: url(http://www.giantesssex.com/image/giantessbanner2.jpg);
    background-repeat: no-repeat;
    width: 800px; height:350px;
    margin-left: auto;
    margin-right: auto;
    padding: 0px;
    border-bottom: 1px solid #444;
    }

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags