Hallo,
ich möchte mehrere Bilder mit einem mousover ausstatten.
Die Struktur ist folgendermaßen aufgebaut
Code:
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12:
| | <div id="eins">
<img class="out" ....>
<img class="out1" ....>
<img class="out2" ....>
<img class="out3" ....>
</div>
<div id="eins">
<img class="out" ....>
<img class="out1" ....>
<img class="out2" ....>
<img class="out3" ....>
</div> |
für die Ansteuerung per jQuery
Code:
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13:
| | $(document).ready(function(){
$("#eins").hover(
function() {
$(this).find(".out").stop().animate({"opacity": "0"}, "200");
$(this).find(".out1").stop().animate({"opacity": "0"}, "200");
},
function() {
$(this).find(".out").stop().animate({"opacity": "1"}, "200");
$(this).find(".out1").stop().animate({"opacity": "1"}, "200");
}
);
}); |
das Problem ist, das nur die Bilder im ersten divblock einen mousover haben.
Wie kann ich das Problem beheben?