jQuery淡入淡出的链接,除了那些是图像的链接?

jQuery淡入淡出的链接,除了那些是图像的链接?,jquery,image,fading,Jquery,Image,Fading,我用jQuery编写了一个非常简单的脚本。这个想法是淡入所有链接与不透明,除了链接是图像 这是我的密码: $('#content_wrapper a, #footer_wrapper a, .dcmenu_market_link a').not('a img').each(function() { $(this).css("opacity", "0.6"); $(this).hover(function() { $(this).addClass('fade');

我用jQuery编写了一个非常简单的脚本。这个想法是淡入所有链接与不透明,除了链接是图像

这是我的密码:

$('#content_wrapper a, #footer_wrapper a, .dcmenu_market_link a').not('a img').each(function() {
    $(this).css("opacity", "0.6");
    $(this).hover(function() {
        $(this).addClass('fade');
        $(this).stop().animate({ opacity: 1.0 }, 600);
    },
    function() {
        $(this).stop().animate({ opacity: 0.6 }, 600);
        $(this).removeClass('fade');
    });         
});

这应该可以得到所有不包含图像的链接-

$('a:not(:has(img))')

杰出的很高兴这有帮助。如果答案有帮助,请不要忘记接受。谢谢:)