Thread Starter
Antoine
(@ant1busted)
It works, thanks. Do you think I could customize the template of visual portfolio to use an ACF field that contains the gif image? Can I just override the portfolio template to add a data attribute to the image tag?
Thread Starter
Antoine
(@ant1busted)
Hi
Thanks for your reply.
This website does this kind of hover animation : https://wizz.fr/ (in the projects section)
my website is at : https://www.studio-oracle.fr
and I tried a very simple jquery to replace the static image by an animated GIF like this :
jQuery(function($) {
$(“img.attachment-vp_xl”).on(
{ “mouseover” : function() { this.src = ‘http://www.studio-oracle.fr/wp-content/uploads/2018/11/ESCAPE-TIME_1.gif’; }
, “mouseout” : function() { this.src=’images/tile_4.jpg’; }
});
});