jquery鼠标悬浮翻转缩略图

来源:https://www.sucaihuo.com/js/766.html 2016-02-14 19:00浏览(908) 收藏

jquery hover鼠标悬停图片特效,当鼠标滑过品牌图片,隐藏的图片会翻转过来。
jquery鼠标悬浮翻转缩略图
分类:图片代码 > 缩略图 难易:高级
查看演示 下载资源 下载积分: 20 积分

品牌图片列表

<div class="brand">
    <a target="_blank" href="http://www.sucaihuo.com/"><img alt="兰芝" src="images/20121119104931.jpg" /></a>
    <a target="_blank" href="http://www.sucaihuo.com/"><img alt="丝塔芙" src="images/20121015052055.jpg" /></a>
    <a target="_blank" href="http://www.sucaihuo.com/"><img alt="玉兰油" src="images/20121123030707.jpg" /></a>
</div>
//品牌翻转
var allBrandAnimate = function(t, d) {
    if (t.find('.brand b').length != 0) {
        return false;
    }
    t.find('.brand a').each(function() {
        $(this).append('<b>' + $(this).find('img').attr('alt') + '</b>')
    });
    t.find('.brand a').hover(function() {
        $(this).find('img').stop().animate({'height': 0, 'top': '35px'}, d, function() {
            $(this).hide().next().show();
            $(this).next().animate({
                'height': '70px',
                'top': '0'
            }, d);
        });
    }, function() {
        $(this).find('b').animate({'height': 0, 'top': '35px'}, d, function() {
            $(this).hide().prev().show();
            $(this).prev().animate({
                'height': '70px',
                'top': '0'
            }, d);
        });
    });
}
allBrandAnimate($('.allbrand'), 80);
标签: 翻转品牌
评论0
头像

系统已开启自动识别垃圾评论机制,识别到的自动封号,下载出错或者资源有问题请联系全栈客服QQ 1915635791

1 2