We’re using a plugin called “Custom Product Tabs for WooCommerce” to add extra tabs to our product pages.
However, as you click each tab the browser scrolls a few pixels towards the top of the site.
I’ve investigated this issue with the plugin developer.
They identified this code in corporate-plus-custom.js as the source as the issue:
$(‘a[href*=”#”]’).click(function(event){
$(‘html, body’).animate({
scrollTop: $( $.attr(this, ‘href’) ).offset().top-$(‘.at-navbar’).height()
}, 1000);
event.preventDefault();
});
If I comment out this code then the site works as expected.
What can we do to fix this without editing the code?
Thanks
Chris