• I would like to know how to center two divs side-by-side. Here is the code I have:

    In my header area I have created 3 widget areas, equally spaced. Into each one I’ve put a text widget. In the text widget of the far left area I have the following code:

    <div id="days">Mon & Fri<br>
    Tue & Thu<br>
    Wed<br>
    Sat<br></div>
    <div id="hours">9-5<br>
    12-8<br>
    9-1<br>
    9-3</div>

    In my CSS inserts section I have:

    #days {
    text-align: right;
    float: left;
    padding-right: 10px;
    }
    #hours {
    text-align: left;
    float: left;
    padding-left: 10px;
    }

    Now I just need to center both days and hours within the far right text widget. I’ve tried several things but nothing’s worked.

Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Center two divs side-by-side’ is closed to new replies.