|
|||
probleme mit verschachtelung
moin. bin neu hier und auch neu bei css.
habe vor folgendes layout mit css umzusetzen (head.jpg). hatte mir das strukturell so gedacht: Code:
<div id="container"> <div id="head"> <div id="boxen"> <div id="box1"></div> <div id="box4"></div> <div id="box2"></div> <div id="box3"></div> </div> <div id="menue"></div> </div> </div> Code:
#container{ height: 650px; width: 1000px; margin-top: 100px; background-color: #FFFF00; } #head{ height: 175px; width: 100%; position: relative; left: 0px; top: 0px; background-color: #FF0000; } #menue{ left: 0px; top: 128px; float: left; position: relative; height: 30px; width: 100%; background-color: #0f0052; } #boxen { top: 0px; left: 12px; float: left; width: 220px; position: relative; } #box1 { float:left; top: 0px; left: 0px; width: 35px; height: 35px; background-color: #9f99ba; } #box2 { float: left; top: 0px; left: 26px; width: 35px; height: 35px; background-color: #7b73a0; position: relative; } #box3 { float:right; top: 0px; right: 26px; width: 35px; height: 35px; background-color: #574c86; position: relative; } #box4 { float:right; top: 0px; left: 0px; width: 35px; height: 35px; background-color: #33266c; } könnt ihr mir da weiterhelfen? vielleicht ist mein ansatz auch total falsch... bin für alles dankbar. |
Sponsored Links |
|
||||
Du baust ein "wunderschöne" Div-Suppe!
Überschriften gehören in <h1>,<h2> usw. Text in <p> Listen (auch Navigationen) in <ul>. <Div> benuzt man nur, um Gruppen von Elementen zu verbinden, damit man diese einfacher positionieren kann. Semantisch geben sie keinen Sinn und sollten deshalb, wie alle semantisch sinnlosen Elemente, sparsam verwendet werden. Setz das erstmal um und dann solltest du dir die Frage stellen: Wieso du "position:relative" nutzen willst und nicht versuchst die Elemente mit "float" zu positionieren.
__________________
Ohne Quelltext gibts selten Hilfe. Also: Onlinebeispiel hochladen und Link bereitstellen! Foren-FAQ |
Sponsored Links |
|
||||
Hier: Einführung in XHTML, CSS und Webdesign und Navigation in Listen: Cascading Style Sheets { Tutorials : Site-Navigation mit Listen }
__________________
Ohne Quelltext gibts selten Hilfe. Also: Onlinebeispiel hochladen und Link bereitstellen! Foren-FAQ |
|
|
Ähnliche Themen | ||||
Thema | Autor | Forum | Antworten | Letzter Beitrag |
Verschachtelung von TABLE, DIV & SPAN - Probleme mit Validität | hinkel11 | Site- und Layoutcheck | 4 | 27.09.2009 10:48 |
paar Probleme mit dem CSS Layout | SimonK. | CSS | 6 | 05.10.2008 14:57 |
Probleme mit Div Verschachtelung | XG1|AleX | CSS | 7 | 26.07.2007 18:02 |
IE: Probleme mit ul-Menü | Ares | CSS | 4 | 18.10.2006 11:42 |