Anu88
26.03.2012, 19:38:47
Witam,
korzystam z lightbox2 i mam następujący problem:
zaczynając od zdjęcia 2 do ostatniego w galerii button "next" wyświetla się po prawej stronie całkiem pod zdjęciem. W 1 zdjęciu wyświetla się poprawnie. Podejrzewam, że pojawienie się buttona "prev" przesówa "next" w te pozycje.
Co z tym zrobić?
lobopol
26.03.2012, 20:12:54
Ja bym najpierw pokazał z czym problem, bo niezbyt ciebie rozumiem. next/prev nie powinny ingerować w obrazek bo mają position:absolute
Anu88
26.03.2012, 20:27:02
Wygląda to następująco:
lobopol
26.03.2012, 20:28:52
Cóż obrazek mi pokazał cały kod css jaki użyłeś jak i html. Udostępnij publicznie stronę albo sam odpal firebuga i popatrz.
Anu88
26.03.2012, 20:35:55
CSS - strony i lightboxa w 1 pliku:
<style type="text/css">
html,body{margin:0;padding:0}
body{
background-image: url(../camiza/Image4.jpg); background-position: center;background-size: cover;
font: Segoe Script,sans-serif;text-align:center;color: #404000;
}
h{margin-top: 0px;}
p{margin-left: 10px; margin-right: 10px; margin-top: 0px}
a{display:block;color: #981793;padding:10px;color: #404000}
table{font-size:14px}
a img {
border:0;
}
div#header h1{height:80px;line-height:70px;margin:0;
padding-left:10px;background: #FFF;color: #79B30B}
div#navi
table{background-image: url(../camiza/Image6.gif); font-family:cursive; font-size:large}
div#header{height:80px; width:700px; background-image: url(../camiza/tlo.png); background-position: center;background-size: cover;}
div#container{text-align:left}
div#content p{line-height:1.4}
div#navigation{background:#B9CAFF;overflow-y: scroll}
div#extra{background:#FF8539}
div#footer{background: #7f7f00;color: #FFF}
div#footer p{margin:0;padding:5px 10px}
div#space {backround: #FFF; height 20px}
div#container{width:700px;margin:0 auto}
div#content{float:left;width:490px;background:#cbcc00;height:400px;margin-top: 0px;overflow: auto}
a{color:white;text-decoration: none}
a:hover{color:black}
div#navigation{float:right;width:190px;background: #cbcc00;height:400px;overflow: auto}
div#extra{clear:both;width:100%;background: #7f7f00;height:150px;overflow-y:auto}
#lightbox{ position: absolute; left: 0; width: 100%; z-index: 100; text-align: center; line-height: 0;}
#lightbox img{ width: auto; height: auto;}
#lightbox a img{ border: none; }
#outerImageContainer{ position: relative; background-color: #fff; width: 250px; height: 250px; margin: 0 auto; }
#imageContainer{ padding: 10px; }
#loading{ position: absolute; top: 40%; left: 0%; height: 25%; width: 100%; text-align: center; line-height: 0; }
#hoverNav{ position: absolute; top: 0; left: 0; height: 100%; width: 100%; z-index: 10; }
#imageContainer>#hoverNav{ left: 0;}
#hoverNav a{ outline: none;}
#prevLink{ width: 49%; height: 100%; background-image: url(data:image/gif;base64,AAAA); /* Trick IE into showing hover */ display: block; }
#nextLink{ width: 49%; height: 100%; background-image: url(data:image/gif;base64,AAAA); /* Trick IE into showing hover */ display: block; }
#prevLink { left: 0; float: left;background: url(../camiza/images/prevlabel.gif) left 15% no-repeat;}
#nextLink { right: 0; float: right;background: url(../camiza/images/nextlabel.gif) right 15% no-repeat;}
#prevLink:hover, #prevLink:visited:hover { background: url(../camiza/images/prevlabel.gif) left 15% no-repeat; }
#nextLink:hover, #nextLink:visited:hover { background: url(../camiza/images/nextlabel.gif) right 15% no-repeat; }
#imageDataContainer{ font: 10px Verdana, Helvetica, sans-serif; background-color: #fff; margin: 0 auto; line-height: 1.4em; overflow: auto; width: 100% ; }
#imageData{ padding:0 10px; color: #666; }
#imageData #imageDetails{ width: 70%; float: left; text-align: left; }
#imageData #caption{ font-weight: bold; }
#imageData #numberDisplay{ display: block; clear: left; padding-bottom: 1.0em; }
#imageData #bottomNavClose{ width: 66px; float: right; padding-bottom: 0.7em; outline: none;}
#overlay{ position: absolute; top: 0; left: 0; z-index: 90; width: 100%; height: 500px; background-color: #000; }
</style>
nazwa wyświetlanego zdjęcia jest pobierana z bazy danych, dlatego php wyświetla zdjęcie w następujący sposób:
echo "<td width=\"90\"><a href=\"".$r['nazwa']."\" rel=\"lightbox[roadtrip]\"><img src=\"".$r['nazwa']."\" width=\"100%\" height=\"100%\"></a></td> ";
lobopol
27.03.2012, 08:11:14
myślisz, że bez bbcode się będzie ktoś przez ten maczek przekopywał? Daj demo online.
To jest wersja lo-fi głównej zawartości. Aby zobaczyć pełną wersję z większą zawartością, obrazkami i formatowaniem proszę
kliknij tutaj.