jQuery实现鼠标划过展示大图的方法

2020-05-22 21:57:25易采站长站整理

            else if(toLeft<0){
                    $(“#hideBox”).css({left:wrapWidth-boxWidth});
            }
            if(toTop>0){
                    $(“#hideBox”).css({top:pos.top});
            }
            else if(toTop<0){
                    $(“#hideBox”).css({top:wrapHeight-boxHeight});
            }          
            $(“#hideBox”).show();          
        });
        $(“#hideBox”).mouseout(function(){
            $(this).hide();
        });    
    });
</script>
</head>
<body>
<div class=”wrap”>
    <table>
        <tr>
            <td><div><b>15</b><a id=”g1″ class=”s” href=”#”>名称1</a></div></td>
            <td><div><b>16</b><a id=”g2″ href=”#”>名称2</a><br />
                    <a id=”g3″ href=”#”>名称3</a></div></td>
            <td><div><b>15</b><a id=”g3″ class=”s” href=”#”>名称1</a></div></td>
            <td><div><b>15</b><a id=”g4″ class=”s” href=”#”>名称1</a></div></td>
        </tr>
        <tr>
            <td><div><b>15</b><a id=”g5″ class=”s” href=”#”>名称1</a></div></td>