zurück zur Startseite
  


Zurück XHTMLforum > (X)HTML und CSS > CSS
Seite neu laden Problem mit position:relative;

Antwort
 
LinkBack Themen-Optionen Ansicht
  #1 (permalink)  
Alt 08.04.2007, 17:23
Neuer Benutzer
neuer user
Thread-Ersteller
 
Registriert seit: 04.04.2007
Beiträge: 7
McCoRmIcK befindet sich auf einem aufstrebenden Ast
Standard Problem mit position:relative;

Hallo

Habe folgenden Code

Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <style type="text/css">
	<!--

	* { margin: 0; padding: 0; }
	body {
	width:983px;
	margin:auto;
	text-align:center;
	background:#303030;
	font-family : Verdana;
	font-size : 12px;
	color : #ccc;
	}
	
	//-->
	</style>
</head>
<body class="">

<div style="text-align:left;position:relative;">


	<div style="position:absolute;left:0px;top:0px;width:651px;height:100%">

		<div style="z-index:1;background-image: url('../img/rand_links.gif');background-repeat: repeat-y;position:absolute;left:0px;top:0px;width:597px;height:100%;"></div>
		<div style="z-index:1;background-image: url('../img/rand_rechts_mitte.gif');background-repeat: repeat-y;position:absolute;right:0px;top:0px;width:54px;height:100%;"></div>

		<div style="z-index:2;background-image: url('../img/rand_oben.gif');background-repeat: no-repeat;position:absolute;left:0px;top:0px;width:597px;height:2px;"></div>
		<div style="z-index:2;background-image: url('../img/rand_rechts_oben.gif');background-repeat: no-repeat;position:absolute;right:0px;top:0px;width:54px;height:352px;"></div>

		<div style="z-index:2;background-image: url('../img/rand_rechts_unten.gif');background-repeat: no-repeat;position:absolute;right:0px;bottom:0px;width:54px;height:31px;"></div>
		<div style="z-index:2;background-image: url('../img/rand_unten.gif');background-repeat: no-repeat;position:absolute;left:0px;bottom:0px;width:597px;height:6px;"></div>


		<div style="z-index:2;position:relative;left:0px;top:0px;width:597px;height:100%;padding:8px">
			Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt 
			Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt
			Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt 
			Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt Inhalt 
		</div>

	</div>

</div>

</body>
</html>
Sobald ich im ersten Div das "position:relative;" einfüge um den ganzen weiteren Kram zentrieren zu können oder im Textfluß zu benutzen, werden alle anderen Elemente falsch positioniert.
Ist das "position:relative;" weg sieht meine gebaute Box so aus wie sie aussehen soll. Steht aber dann auch ganz oben links und nicht wie im Beispiel in der Mitte.
Sieht evtl. jemand nen Fehler oder nen Grund warum sich alles verschiebt wenn ich die Box weiter verwenden will?

##Edit
Hat sich erledigt

Geändert von McCoRmIcK (09.04.2007 um 00:04 Uhr)
Mit Zitat antworten
Sponsored Links
Antwort

Themen-Optionen
Ansicht

Forumregeln
Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus


Ähnliche Themen
Thema Autor Forum Antworten Letzter Beitrag
Problem mit z-index - funzt nicht RizzzO CSS 8 19.10.2009 23:51
Position Problem im IE7, Firefox und IE8 funktioniert christof11 CSS 1 07.09.2009 15:23
Problem bei CSS Grundlayout DasSauerkraut CSS 0 10.08.2009 22:35
CSS Problem: Links im FF und Chrome nicht klickbar nur im IE yonthebeach CSS 5 12.07.2009 16:12
Problem mit Background-Color im FireFox to.ni CSS 2 31.08.2004 12:13


Alle Zeitangaben in WEZ +2. Es ist jetzt 12:09 Uhr.