图片悬停效果 - jQuery的

图片悬停效果 - jQuery的

问题描述:

我想知道,如果有,可以在http://gridonic.ch/?g=1图片悬停效果 - jQuery的

你可以看一下作为镶嵌上看到悬停执行类似操作(即显示文本)的任何jQuery插件;

http://buildinternet.com/project/mosaic/1.0/

+0

感谢muhammet :)会给chk! – user1184100 2012-02-24 07:34:18

这可以帮助你。

$('.div img').hover(
function(){ 
$(this).stop().animate({marginTop:'-25px',}, 300); 
}, 
function(){ 
$(this).stop().animate({marginTop:'0px',}, 300); 
} 

);

此查询的效果与您想要的效果相同。

为了解释代码

.div =类FO您的格或任何元件

function(){ 
$(this).stop().animate({marginTop:'-25px',}, 300); 
}, 

当图像是将鼠标悬停它将向上移动方向与marginTop的帮助这个代码装置:' - 25像素”

和代码

function(){ 
$(this).stop().animate({marginTop:'0px',}, 300); 
} 

它意味着,当它不是在悬停或鼠标移出图像时,它将返回到其原始位置。

您可以随时查看您想要的速度或想要的位置。