Zeromancer: Div neben- und untereinander anordnen

Beitrag lesen

Hallo HP-Bauer,

ich würde die Sache anders angehen:

  
<body>  
<div id="aussen">  
  
<div id="ro">   Inhalt rechts oben  
</div>  
  
<div id="lo"> Inhalt links oben  
</div>  
  
<div id="ru"> Inhalt rechts unten  
</div>  
  
<div id="lu">  Inhalt links unten  
</div>  
  
</div>  
</body>  

  
body {  
  padding:0px;  
  margin:0px;  
}  
div#aussen {  
  width:582px;  
  height:500px;  
  position:absolute;  
  top:50%;  
  left:50%;  
  margin:-250px 0 0 -291px;  
  border:solid 1px #f00;  
}  
  
div#lo {  
  width:245px;  
  height:140px;  
  border:solid 1px #000;  
  margin:20px 20px;  
}  
div#ro {  
  width:245px;  
  height:140px;  
  float:right;  
  border:solid 1px #0f0;  
  margin:20px 10px;  
}  
div#lu {  
  width:245px;  
  height:140px;  
  border:solid 1px #00f;  
  margin:20px 20px;  
}  
div#ru {  
  width:245px;  
  height:140px;  
  float:right;  
  border:solid 1px #ff0;  
  margin:0px 10px;  
}  

Mit "margin" und "padding" musst du mal ein bißchen spielen und rechnen. Sag mal Bescheid, wie es weitergeht!

Mit freundlichen Grüßen,
André