• Jetzt anmelden. Es dauert nur 2 Minuten und ist kostenlos!

variable höhe in css?

csigg

Neues Mitglied
Hallo,

ich hab gerade mal versucht ein Tabellenloses Template zu erstellen, nur mit css.
Soweit hat das ganze auch gut geklappt, mit der Ausnahme, dass ich mit der höhe ein Problem habe.
Mein gerüst sieht ungefähr so aus:
PHP:
<div id="headerRow">
        <div id="headerLeft">
        </div>
        <div id="headerRight">
        </div>
</div>
<div id="mainRow">
        <div id="mainLeft">
        </div>
        <div id="mainRight">
         </div>
</div>
<div id="footerRow">
        <div id="footerLeft">
        </div>
        <div id="footerRight">
         </div>
</div>
und meine CSS (gekürtzt):
PHP:
 #headerRow {
    width:                 800px;
    height:             80px;
   }
 #mainRow {
       width:                 800px;
    height:             inherit;
   }
   
   #footerRow {
       width:                 800px;
    height:             60px;
    margin-top:            2px;
   }

#mainLeft {
       background-color:    #FFFFFF; 
      width:                 160px;
    height:             auto;
    float:                left;
   }
   
   #mainright {
       background-color:    #FFFFFF; 
      width:                 620px;
    height:             auto;
       float:                left;
    }
   
   #headerLeft {
       background-color:    #FFFFFF; 
      width:                 30%;
    height:             70px;
    float:                left;
    }
   
   #headerRight {
       background-color:    #FFFFFF; 
      width:                 50%;
    height:             70px;
       float:                right;
    }
   

   
   #footerRight {
       background-color:    #FFFFFF;
    width:                300px;
    float:                right;
    }
   
   #footerLeft {
       background-color:    #FFFFFF;
    width:                300px;
    float:                left;
   }
Jetzt hab ich allerdings dass Problem mit der Höhe, wenn mal ein text länger wird.
Die Box mainLeft ist immer genau so hoch wie dass Menü darin, und die Box mainRight ist immer genau so groß wie der Content darin.
Die mainRow ist nur noch ca 50px groß?
Wie bekomm ich denn die immer so hin wie ihr inhalt, also wie die Boxen mainLeft und mainRight?
Und wie bekomm ich die mainLeft und mainRight auf min.400px, wenn der Inhalt größer ist auch mehr?
 
super, danke!!
Ich habs jetzt hinbekommen...

Nur was mir noch fehlt:
im Moment ist die Seite immer so lange wie die Box,
ich hätte Sie aber gerne min. 400px hoch, wie bekomm ich denn dass hin?
 
Zurück
Oben