双击无法工作

我正在尝试使图像可双击,但是在隐含它时(请参见下面的代码),它将无法正常工作,更让我感到困惑的是,当我删除第一行中img标签的结束标签然后它可以工作时,但所有图片会重定向到doubleclick(1.ballauf.org)上的第一个链接

<div ondblclick="window.location='http://1.ballauf.org/Home'"><img src="_dsc5696.jpg" name="bild00" class="BILDER" id="test" style="position:absolute; z-index:12; left: 573px; top: 86px;"></div>
<div ondblclick="window.location='https://www.google.com/'"><img src="_dsc5872.jpg" name="bild12" class="BILDER" id="test" style="position:absolute; z-index:1; left: 645px; top: 411px;"></div>
<img src="_dsc4190.jpg" name="bild01" class="BILDER" id="test" style="position:absolute; z-index:2; left: 694px; top: 261px;">
<img src="_dsc4386.jpg" name="bild02" class="BILDER" id="test" style="position:absolute; z-index:3; left: 671px; top: 372px;">
<img src="_dsc4821.jpg" name="bild03" class="BILDER" id="test" style="position:absolute; z-index:4; left: 799px; top: 352px;">
<img src="_dsc5491.jpg" name="bild04" class="BILDER" id="test" style="position:absolute; z-index:5; left: 669px; top: 250px;">
<img src="_dsc5494.jpg" name="bild05" class="BILDER" id="test" style="position:absolute; z-index:6; left: 690px; top: 34px;">
<img src="_dsc5502.jpg" name="bild06" class="BILDER" id="test" style="position:absolute; z-index:7; left: 639px; top: 146px;">
<img src="_dsc5538.jpg" name="bild07" class="BILDER" id="test" style="position:absolute; z-index:8; left: 791px; top: 268px;">
<img src="_dsc5554.jpg" name="bild08" class="BILDER" id="test" style="position:absolute; z-index:9; left: 611px; top: 304px;">
<img src="_dsc5615.jpg" name="bild09" class="BILDER" id="test" style="position:absolute; z-index:10; left: 692px; top: 279px;">
<img src="_dsc5748.jpg" name="bild10" class="BILDER" id="test" style="position:absolute; z-index:11; left: 658px; top: 371px;">

</map>
<!--        <a href="1.ballauf.org"><img src="_dsc5696.jpg"></a>        -->
<script type="text/javascript">
<!--

SET_DHTML("bild00","bild01","bild02","bild03","bild04","bild05","bild06","bild07","bild08","bild09","bild10","bild11","bild12");

//-->
</script>

I should also mention SET_DHTML() makes the images draggable.

评论