 $("#container").on({ "mouseenter": function () {     $(this).stop().animate({         "opacity": "0"     }, 000);     $(this).prev(".caption").stop().fadeTo(0, 0).css('visibility', 'visible').fadeTo('fast', 0); }, "mouseleave": function () {     $(this).stop().animate({         "opacity": "0.0"     }, 000);     $(this).prev(".caption").stop().fadeTo(0, 0).css('visibility', 'visible').fadeTo('fast', 0); }