Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Automatyczne rozciąganie się DIVa z textem - jak wyłączyć
AboutMe
post
Post #1





Grupa: Zarejestrowani
Postów: 261
Pomógł: 0
Dołączył: 24.02.2008

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


Witam,

Jak zrobić żeby text1 i text2 ne rozciągał się automatycznie do szerokości #container

  1. #container { width:900px; margin:0 auto; }
  2. #text1 { margin-top:140px; margin:0 auto; text-align:center; }
  3. #text2 { margin-top:100px; margin:0 auto; text-align:center; }
  4.  
  5. <div id="container">
  6.  
  7. <div id="text1">xxxxx xxxx xxxxxx</div>
  8. <div id="text2">xxxxxx xxxxx xxxxx</div>
  9.  
  10. </div><!-- #container -->
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 3)
Tomplus
post
Post #2





Grupa: Zarejestrowani
Postów: 1 883
Pomógł: 231
Dołączył: 20.03.2005
Skąd: Będzin

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


myślę że powinieneś ustalić sztywne szerokości DIVów text1,2
Go to the top of the page
+Quote Post
ksenonlogin
post
Post #3





Grupa: Zarejestrowani
Postów: 123
Pomógł: 3
Dołączył: 29.10.2011

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


#container { width:900px; margin:0 auto; overflow: hidden;}
#text1 { margin-top:140px; margin:0 auto; text-align:center; width:XXpx; overflow: hidden;}
#text2 { margin-top:100px; margin:0 auto; text-align:center; width:XXpx; overflow: hidden;}
Go to the top of the page
+Quote Post
php.helper
post
Post #4





Grupa: Zarejestrowani
Postów: 4
Pomógł: 0
Dołączył: 9.08.2012

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


kolega napisał tutaj chyba najproścej jak się dało (IMG:style_emoticons/default/smile.gif)
Go to the top of the page
+Quote Post

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

 



RSS Aktualny czas: 19.09.2025 - 18:41