Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Margines górny działa na niechcianym elemencie.
activestate
post 23.08.2012, 12:27:41
Post #1





Grupa: Zarejestrowani
Postów: 13
Pomógł: 0
Dołączył: 23.08.2012

Ostrzeżenie: (0%)
-----


Witam,
Mam pytanie, czy jest to normalne zachowanie, że element parent (#a) dziedziczy od children (#cool.gif margines górny?

#a {
background-color: #900;
height: 900px;
width: 100%;
}
#b {
height: 400px;
width: 70%;
margin-right: auto;
margin-left: auto;
background-color: #969;
margin-top: 120px;
}
</style>
</head>

<body>
<div id="a">
<div id="b">Content for id "d" Goes Here</div>
</div>

Teraz, zamiast marginesu dla #b, #a ma margines.
Nie mogę znaleźć info na ten temat, proszę o podpowiedź.
Dzięki.
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Wersja Lo-Fi Aktualny czas: 14.08.2025 - 14:34