CSS - div Inhalt links ausrichten



  • Hallo zusammen,

    ich möchte den Inhalt meiner Div-Boxen links ausrichten.
    Der gesamte body ist mit margin:auto; zentriert.

    Den entsprechende div-box richte ich mit margin-left:5px; aus.
    Funzt allerdings nicht!

    Hier mein Code:

    body
    {
     font-family:Verdana;
     font-size:12px;
     background-color:#cccccc;
     text-align:center;
     width:760px;
     margin:auto;
    }
    
    /* content-box */
    .content_head
    {
    margin-bottom:0px;
    margin-top:59px;
    margin-left:5px; <-------------------HIER IST DAS PROBLEM!!!
    }
    
    .content_box
    {
    margin-top:0px;
    width:754px;
    height:100px;
    background-color:#dddddd;
    border:1px solid #111111;
    border-left:3px solid #111111;
    -moz-border-radius-topleft:10px;
    -moz-border-radius-topright:10px;
    -moz-border-radius-bottomleft:10px;
    -moz-border-radius-bottomright:10px;
    }
    

    Danke für alle Antworten!

    Curry-king!



  • Den Inhalt?
    text-align: left;
    ?



  • Tatsache, es klappt!

    Danke und trotzdem :schland: Kopf hoch!


Anmelden zum Antworten