So, on this page: http://www.caliberprotoproject.com/dealers/
I have an SVG set up with anchor tags that correspond to different color sections below it.
However, the theme’s smooth scrolling doesn’t seem to work in conjunction with it.
I inserted this script into the code block (as well have tried calling it from a folder directory under my child theme) to no avail:
$(‘a’).click(function(){
$(‘html, body’).animate({
scrollTop: $( $.attr(this, ‘href’) ).offset().top
}, 500);
return false;
});
Any ideas?
Hi tlow87!
Seems like something is causing a conflict with the themes javascript. If you have any plugins running, deactivate them and then check things out.
Also try removing the js snippet above if you’ve got it placed within something that isn’t getting enqueued. Then we’ll see where we are at and if the current js error gets cleaned up.
Cheers!
Devin
I’ve removed the snippet and disabled plugins. No effect.
Hi!
Not sure if this will fix the issue but try to replace the xlink:href attribute with a simple href.
Best regards,
Peter
Thanks Dude,
Unfortunately it didn’t work.
Hey!
I tagged this thread for Kriesi. I couldn’t find a quick solution and I’ll leave it up to him to decide whether he wants to support the xlink:href attribute or not.
Regards,
Peter
Thanks so much dude! I appreciate it!