CSS Gallerie funktioniert nicht im IE (vllt z-index??? )

CSS Gallerie funktioniert nicht im IE (vllt z-index??? )

Beitragvon DaCrash » 25.07.2006, 19:43

Hallo, ich bin neu hier und hoffe ich verzettel mich nicht gleich bei meiner ersten Fragestellung, bzw schreibe nicht im falschem Forum.


Also, ich bin dabei eine CSS Gallerie für ein paar Bilder zu erstellen. Hat auch alles super geklappt, bis ich irgendwann was geändert habe. Ich komme einfach nicht hinter den Fehler. Wie gesagt es lief vor ner Stunde (auch im IE). Vllt hab ich auch nur zu lange davor gesessen und sehe den Fehler jetzt einfach nicht.

--->Hier die Seite online zum Testen<---

Naja zum Problem:

Beim hover wird das bereits geladene Bild in (bzw. über) dem Kasten angezeigt. Beim focus bleibt es dann stehen. Durch den Z-Index ist es aber weiterhin möglich, sich die anderen Bilder per hover anzeigen zu lassen. (hoffe es ist verständlich ?!?! :? )
Naja und nun gehtes nicht mehr im IE.

Hier der HTML-Code inklusive dem CSS-Code. Ich schätze mal die Bilder Braucht ihr nicht.

Code: Alles auswählen
<style type="text/css">
#pic {

height:250px;
width: 500px;
border:0px;
position:relative;
}
#pic a.p1, #pic a.p1:visited {float : right; margin : 4px 10px 4px 10px; border:0px; top:0; left:0; border:0;}
#pic a .large {position:absolute; width:1px; height:1px; border:0px; top:-1px; left:-1px; z-index:100;}
#pic a.p1:hover .large {position:absolute; top:15px; left:13px; width:316px; height:180px;  z-index:100;}
#pic a.p1:active .large {position:absolute; top:15px; left:13px; width:316px; height:180px; z-index:10;}
#pic a.p1:focus .large {position:absolute; top:15px; left:13px; width:316px; height:180px;  z-index:10;}
#pic a img {border:#CCCCCC 1px solid;}



#picthumbs {
   float : left;
   height : 180px;
   width : 110px;
   padding :  5px 0px 13px 0px;
   overflow: hidden;
   border-left: #999999 1px solid;
   border-bottom: #999999 1px dotted ;
   margin: 10px 0px 0px 27px;
   text-decoration:none;
   }

#picweiter {
   height : 25px;
   width : 110px;
   float : left;
   padding-top :  5px;
   overflow:  hidden;
   margin: 0px 0px 0px 27px;
   border-left: #999999 1px solid;
   text-align:center;

   
   }
   
#picpic {
   height : 226px;
   width : 324px;
   float : left;
   padding : auto;
   overflow:  hidden;
   margin: 10px 0px 0px 8px;
   border: #999999 1px solid;
   background: #E5E5E5;

   }
   
   #pictext {
   font-style:italic;
   font-size:30px;
   font-family: "Monotype Corsiva";
   text-align:center;
   position:absolute;
   top: 80px;
   left:110px;
   color:#666666;
   
   }
      #pictext2 {
   font-size:16px;
   font-family: "Monotype Corsiva";
   text-align:center;
   position:absolute;
   top: 115px;
   left:145px;
   color:#666666;
   
   }
</style>
<div id="pic" >

   <div id="picpic">
      <div id="pictext">Have Fun !</div>
      <div id="pictext2">-Seite 2-</div>
    </div>   

   
   <div id="picthumbs">
   
<a class="p1" href="#nogo" title="thumbnail image">
<img alt="Bild 1" src="images/fotos/small/thumb1.jpg"/>
<img alt="Bild 2"  src="images/fotos/medium/pic1.jpg"  class="large"/>
</a>

<a class="p1" href="#nogo" title="thumbnail image">
<img alt="Bild 3" src="images/fotos/small/thumb2.jpg"/>
<img alt="Bild 4"  src="images/fotos/medium/pic2.jpg"  class="large"/>
</a>

<a class="p1" href="#nogo" title="thumbnail image">
<img alt="Bild 5" src="images/fotos/small/thumb3.jpg"/>
<img alt="Bild 6"  src="images/fotos/medium/pic3.jpg"  class="large"/>
</a>   

   </div>

   <div id="picweiter">

      <a href="main.php?action=foto1">1</a>
      <a href="main.php?action=foto2">2</a>
      <a href="main.php?action=foto3">3</a>
      <a href="main.php?action=foto4">4</a>   
      
   </div>
</div>


Danke schon einmal im Voraus!
DaCrash
neu hier
 
Beiträge: 4
Registriert: 25.07.2006, 19:33

Beitragvon Laus » 26.07.2006, 11:23

Hallo

Setze auf deiner Testseite einen korrekten Doctype, die Tags <html> <head> <body>und die Schließenden Tags dazu dann läufts wieder :wink:

Übrigens der von dir gepostete Code stimmt nicht mit dem der Testseite überein.

Gruß Xaver
Lachen ist kein schlechter Anfang und bei weitem das beste Ende.
(Oscar Wilde)
Benutzeravatar
Laus
Moderator
 
Beiträge: 1229
Registriert: 25.02.2006, 00:30
Wohnort: Furth im Wald

Beitragvon DaCrash » 26.07.2006, 15:47

Danke schön , aber ich steige einfach nicht durch , welchen Doctype ich nehmen muss, dass es im IE funktioniert. Hab mich auf sämtlichen Seiten infromiert, aber kein Doctype hat das gewünschte ergebnis präsentiert...


Könntest du mir da nochmal helfen ?


MfG B
DaCrash
neu hier
 
Beiträge: 4
Registriert: 25.07.2006, 19:33

Beitragvon Laus » 26.07.2006, 19:10

So müsste es gehen, getestet im IE6 IE7.
Code: Alles auswählen
<!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">

<head>
<meta http-equiv="Content-Type" content="html/text; charset=iso-8859-1" />
<title>Unbenanntes Dokument</title>

<style type="text/css">
#pic {

height:250px;
width: 500px;
border:0px;
position:relative;z-index:100;
}
#pic a.p1:hover {text-decoration:none; background-color:#8c97a3; color:#000;}
#pic a.p1, #pic a.p1:visited {display:block;z-index:100;float.left; margin: 4px 10px 4px 10px; border:0px; top:0; left:0;}
#pic a .large {position:absolute; width:1px; height:1px; border:0px; top:-1px; left:-1px; z-index:100;}
#pic a.p1:hover .large {position:absolute; top:15px; left:13px; width:316px; height:180px;  z-index:100;}
#pic a.p1:active .large {position:absolute; top:15px; left:13px; width:316px; height:180px; z-index:10;}
#pic a.p1:focus .large {position:absolute; top:15px; left:13px; width:316px; height:180px;  z-index:10;}
#pic a img {border:#CCCCCC 1px solid;}



#picthumbs {
   float : left;
   height : 180px;
   width : 110px;
   padding :  5px 0px 13px 0px;
   overflow: hidden;
   border-left: #999999 1px solid;
   border-bottom: #999999 1px dotted ;
   margin: 10px 0px 0px 27px;
   text-decoration:none;
         z-index:10;
   }

#picweiter {
   height : 25px;
   width : 110px;
   float : left;
   padding-top :  5px;
   overflow:  hidden;
   margin: 0px 0px 0px 27px;
   border-left: #999999 1px solid;
   text-align:center;
         z-index:10;

   }

#picpic {
   height : 226px;
   width : 324px;
   float : left;
   padding : auto;
   overflow:  hidden;
   margin: 10px 0px 0px 8px;
   border: #999999 1px solid;
   background: #E5E5E5;
         z-index:10;
   }

   #pictext {
   font-style:italic;
   font-size:30px;
   font-family: "Monotype Corsiva";
   text-align:center;
   position:absolute;
   top: 80px;
   left:110px;
   color:#666666;

   }
      #pictext2 {
   font-size:16px;
   font-family: "Monotype Corsiva";
   text-align:center;
   position:absolute;
   top: 115px;
   left:145px;
   color:#666666;

   }
</style>
</head>

<body>
<div id="content">
<div id="pic" >

   <div id="picpic">

      <div id="pictext">Have Fun !</div>
      <div id="pictext2">-Seite 2-</div>
    </div>


   <div id="picthumbs">

<a class="p1" href="#nogo" title="thumbnail image">
<img alt="Bild 1" src="images/fotos/small/thumb1.jpg"/>
<img alt="Bild 2"  src="images/fotos/medium/pic1.jpg"  class="large"/>
</a>

<a class="p1" href="#nogo" title="thumbnail image">
<img alt="Bild 3" src="images/fotos/small/thumb2.jpg"/>

<img alt="Bild 4"  src="images/fotos/medium/pic2.jpg"  class="large"/>
</a>

<a class="p1" href="#nogo" title="thumbnail image">
<img alt="Bild 5" src="images/fotos/small/thumb3.jpg"/>
<img alt="Bild 6"  src="images/fotos/medium/pic3.jpg"  class="large"/>
</a>

   </div>

   <div id="picweiter">

      <a href="main.php?action=foto1">1</a>
      <a href="main.php?action=foto2">2</a>

      <a href="main.php?action=foto3">3</a>
      <a href="main.php?action=foto4">4</a>

   </div>
</div>
</div>
</body>
</html>
Lachen ist kein schlechter Anfang und bei weitem das beste Ende.
(Oscar Wilde)
Benutzeravatar
Laus
Moderator
 
Beiträge: 1229
Registriert: 25.02.2006, 00:30
Wohnort: Furth im Wald


Moderatoren: Laus, Moderatoren

Ähnliche Beiträge zu "CSS Gallerie funktioniert nicht im IE (vllt z-index??? )"

Zurück zu: CSS für Fortgeschrittene

Wer ist online?

Mitglieder in diesem Forum: 0 Mitglieder und 2 Gäste