|
|
#1 (permalink) |
|
Divlerde Sorun
Sayfa içinde <div> ve <span> etiketli kodlar var. ff de sayfa düzgün ie de sağa kaymış gözüküyor, sabahtan beri bulamadım sorunu en son pes ettim. kod taslağı şu şekilde: Kod:
<body> <center> <div id="container" align="center"> ... ... ... <p id="baslik">HOŞGELDINIZ...</p> <div id="happy"> </div> <div class="desc"> <span class="desc">Lorem Ipsum is simply dummy text of the printing and ... </span></div> </div> </center> </body> Kod:
#baslik {
font-family:"Tw Cen MT",Arial;
font-size:16px;
color:#a5a8a8;
text-align:left;
font-weight:500;
margin-top:-5px;
margin-left:39px;
}
#happy {
width:210px;
height:239px;
margin-top:10px;
margin-right:-350px;
position:relative;
background-image:url(happy.jpg);
background-repeat:no-repeat;
}
div.desc {
margin-left:30px;
margin-top:-230px;
width:300px;
font-family:"Tw Cen MT",Arial;
font-size:14px;
color:#fff;
text-align:left;
position:absolute;
}
span.desc {
font-family:"Tw Cen MT",Arial;
text-align:left;
font-size:14px;
color:#fff;
}
Şimdiden teşekkürler... |
|
|
|
|
|
|
#3 (permalink) |
|
Üyelik Tarihi: 26.07.2005
Yer: Bochum
Mesaj: 225
|
Re: Divlerde Sorun
@metsatöll'ün de belirttiği gibi, tüm align="center" ve <center> etiketlerini silip en üst div'e margin:0 auto; değerini vermek daha mantıklı olacaktır.
__________________
XHTMLMutfağı |
|
|
|
|
|
#4 (permalink) |
|
Üyelik Tarihi: 27.07.2005
Yer: istanbul - ankara
Yaş: 23
Mesaj: 337
|
Re: Divlerde Sorun
|
|
|
|
|
|
#7 (permalink) |
|
Re: Divlerde Sorun
Bunun disinda,
doctype yazmadan, ie de yapacaginiz her denemede, margin:0 auto; düzgün calismaz bilginiz olsun, Kodlariniz arasinda bazi yerler gereksiz uzatilmis, asagidaki sekilde revize ettim fikir vermesi acisindan HTML Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <HTML xmlns="http://www.w3.org/1999/xhtml" XML:lang="tr" lang="tr"> <head> <style> body { background: #606060; } #container { margin: 0 auto; position: relative; width : 800px; } #baslik { font:16px "Tw Cen MT",Arial;; color:#a5a8a8; margin:-5px auto auto 39px; } #happy { float:right; width:210px; background: url(happy.jpg) no-repeat; } div.desc { width:300px; margin-left: 30px; font-family:"Tw Cen MT",Arial; font-size:14px; color:#fff; float:left; } span.desc { font-family:"Tw Cen MT",Arial; font-size:14px; color:#fff; } </style> </head> <body> <div id="container"> <p id="baslik"> hosgeldiniz </p> <div id="happy"> happy </div> <div class="desc"> <span class="desc"> Lorem Ipsum is simply dummy text of the printing and ... </span> </div><br style="clear:both" /> </div> </body> |
|
|
|
|
|
|
#9 (permalink) | |
|
Üyelik Tarihi: 26.07.2005
Yer: Bochum
Mesaj: 225
|
Re: Divlerde Sorun
Alıntı:
clear:left; clear:right; clear:both; clear:none;
__________________
XHTMLMutfağı |
|
|
|
|
|
|
#10 (permalink) |
|
Re: Divlerde Sorun
@muhammet
Burada clear:both ile ilgili bir konu acilmisti, oradaki tartisma sonucu clear:both en mantikli kullanimin background rengine ayarlanmis bir hr tagi oldugu kanisina varmistim Lautreamont'un kisisel cözümünü söylemesi üzerine, kisa yolda <br /> yazdim buraya ama senin bu konudaki kisisel cözümünü sorabilirmiyim, clear:both degerini nasil kullaniyorsun? |
|
|
|
|
| Sponsorlu Bağlantılar | |
|
Zoque.Forum
Reklam
|
|
Zoque'a hoşgeldiniz!