Ocena wątku:
  • 0 głosów - średnia: 0
  • 1
  • 2
  • 3
  • 4
  • 5
[css] Div obok diva
#1
Chciałbym umieścić diva obok diva. A dokładniej chodzi o to, by rightBox był obok content1. RightBox ma być po prawej, a content1 po lewej, walcze z tym już drugi dzień i nie mogę sobie poradzić, próbowałem już z ustawianiem display:inline;, float:left in w obu divach, z clear:both, ale bez skutku
Obecnie to wygląda tak http://postimage.org/image/6hnv6027t/
css code
Kod:
@CHARSET "UTF-8";

body{
    font: normal 100% Helvetica, Arial, sans-serif;
    background-color:#4F4F4F;
    color: #000;
    font-size: 12px;    
    
}

img{
    width:100%;
}



.page{
    margin: 0 auto;
    max-width: 83em;
    background-image: url("../img/strona_tlo.jpg");
    background-position: center;
    background-repeat: repeat-y;
    
}

.banner{
    width:100%;
    background-image: url("../img/banner_tlo.jpg");
    background-position:center;
    background-repeat:no-repeat;
    min-height:30px;
    height:130px;
}

.bannerText{
    margin-left: 0.5em;
    padding-top: 3em;
    font-size: 2em;
}

.menu{
    width:100%;
    font-size:1.25em;
    background-image:url("../img/menu_tlo.png");
    background-position:center;
    background-repeat: repeat-y;
}
a{
    margin: auto 0.5em;
    text-decoration: none;
    color: #000;
}
a:VISITED{

    text-decoration: none;
    color: #000;
}
a:HOVER{
    color: #555;
    text-decoration: underline;
}


.middle{
    min-height:300px;
    min-width:300px;
    max-width: 83em;
    background-image: url("../img/tloPage.png");
    background-position: center;
    background-repeat: repeat-y;
    
}
.content1{
    width:85.5%;
    float:left;
}
.belkaGorna{
    margin-top: 2em;
    margin-left:2em;
    height:25px;
    width:85.5%;
    background-image: url("../img/content1.png");
    background-repeat: no-repeat;
    background-position: left;
    float:left;
}
.content{
    margin-left: 2em;
    min-height:20em;
    float:left;
    width:85.5%;
    background-image: url("../img/content2.png");
    background-position: left;
    background-repeat: repeat-y;
    }
    
.contentHeader{
    margin-left:1em;
    font-size: 1.5em;
    font-family: Georgia,serif;
}
    
    
.belkaDolna{
    margin-left:2em;
    margin-bottom:2em;
    min-height:25px;
    float:left;
    width:85.5%;
    background-image: url("../img/content3.png");
    background-position: left;
    background-repeat: no-repeat;
}


.rightBox{
    float:right;
    min-height:10em;
    width:12.5%;
    background-image: url("../img/rb2.png");
    background-repeat: repeat-y;
    background-position: center;
}
.rightBoxheader{
    text-align: left;
    width:100%;
    background-image: url("../img/rb1.png");
    background-repeat: no-repeat;
    background-position: center;
    
}
.rightBoxTitle{
    font-size: 1.2em;
    margin: 0 0 0 10px;
    text-decoration: underline;
}


.footer{
    clear:both;
    height:100px;
    width:100%;
    background-image:url("../img/stopka_tlo.png");
    background-position: center;
    background-repeat: no-repeat;
    
}


.footerText{
    text-align:center;
    margin: 0 auto;
    font-size: 0.9em;
    height:6em;
    line-height: 4em;
    vertical-align: middle;
    font-weight: normal;
    color:#111;
    }

html code:
Kod:
<body>
<div class="page">                 
    
        <jsp:include page="/template/banner.jsp" />    
        <c:import url="/MenuServ" />
        
        <div class="middle">
        <div class="content1">
        <div class="belkaGorna"></div>
        <div class="content">
        <decorator:body />
        </div>
        <div class="belkaDolna" />
        </div>
        <div class="rightBox" ></div>
        </div>
        
        <jsp:include page="/template/footer.jsp" />
        </div>                            
</body>

Jakieś pomysły?:>
Odpowiedz


Wiadomości w tym wątku
[css] Div obok diva - przez Mtk - 05-10-2012, 02:39
RE: [css] Div obok diva - przez camelrafal - 05-10-2012, 03:54
RE: [css] Div obok diva - przez Kartofelek - 05-10-2012, 15:01
RE: [css] Div obok diva - przez Mtk - 05-10-2012, 19:09
RE: [css] Div obok diva - przez camelrafal - 05-10-2012, 22:18
RE: [css] Div obok diva - przez Mtk - 06-10-2012, 04:16
RE: [css] Div obok diva - przez camelrafal - 06-10-2012, 15:51
RE: [css] Div obok diva - przez Mtk - 07-10-2012, 01:54

Podobne wątki…
Wątek: Autor Odpowiedzi: Wyświetleń: Ostatni post
  USTAWIENIE GADZETOW OBOK SIEBIE burgeros 3 4,966 27-01-2015, 15:02
Ostatni post: mateo
  [css] div obok diva; hover nana 2 2,866 11-12-2012, 23:56
Ostatni post: nana
  [CSS] Problem z pozycjonowaniem diva. Extragracz 5 3,317 31-08-2012, 16:06
Ostatni post: Extragracz
  Dwa elementy menu obok siebie kingu80 3 3,452 17-08-2012, 17:15
Ostatni post: Kartofelek
  onclick.. divy zasłania diva itp. harvester2001 10 5,469 13-07-2012, 21:47
Ostatni post: Kartofelek

Skocz do:


Użytkownicy przeglądający ten wątek: 1 gości
Sponsorzy i przyjaciele
SeoHost.pl