Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [CSS][HTML]problem z wysokością diva w divie
grabek93
post 9.08.2011, 14:35:06
Post #1





Grupa: Zarejestrowani
Postów: 73
Pomógł: 8
Dołączył: 23.09.2010

Ostrzeżenie: (10%)
X----


Mam taki oto kod
  1. <div id="all">
  2. <div id="left">
  3. <div id="last-info">
  4. <div id="last-info-left">
  5. <h1 class="last-info-title">Lorem ipsum dort anum set austrafomilius...</h1>
  6. <p class="last-info-date">22.05.2011</p>
  7. <p class="last-info-text">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce adipiscing feugiat massa,
  8. ac rutrum enim ornare consectetur. Nam eget lacus ut metus mattis mattis...</p>
  9. </div>
  10. <div id="last-info-right">
  11. </div>
  12. </div>
  13. <h2 class="title"></h2>
  14. <p class="text">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce adipiscing feugiat massa,
  15. ac rutrum enim ornare consectetur. Nam eget lacus ut metus mattis mattis...</p>
  16. </div>
  17. <div id="right">
  18. <?php include "right.php"; ?>
  19. </div>
  20. </div>

CSS:
  1. #all{
  2. width: 1000px;
  3. margin: 0 auto 0 auto;
  4. background: #eeeeee;
  5. min-height: 700px;
  6. height: auto;
  7. }
  8.  
  9. body{
  10. font-family: Arial;
  11. margin: 0;
  12. }
  13.  
  14. #left{
  15. float: left;
  16. width: 700px;
  17. }
  18.  
  19. #right{
  20. float: left;
  21. width: 300px;
  22. height: auto;
  23. }
I taki problem, że div "all" nie rozciąga się pod wpływem ilości tekstu w divach "right" i "left". problem na pewno jest błahy, tylko ja nie widzę błędu... jeśli wpisuje LOREM IPSUM bezpośrednio do 'all', wszystko działa. jeśli zaś do jednego z divow w środku, tekst wychodzi poza divy, które powinny się rozciągnąć na wysokość.
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 2)
Damonsson
post 9.08.2011, 15:16:31
Post #2





Grupa: Zarejestrowani
Postów: 2 355
Pomógł: 533
Dołączył: 15.01.2010
Skąd: Bydgoszcz

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


overflow: hidden - dodaj do all
Go to the top of the page
+Quote Post
toffiak
post 9.08.2011, 15:17:43
Post #3





Grupa: Zarejestrowani
Postów: 395
Pomógł: 80
Dołączył: 24.08.2009

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


Poszukaj w googlu pod frazą "clearfix"


--------------------
Go to the top of the page
+Quote Post

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 - 11:36