I've added anchor link on the main page to contacts-module: http://xn--80abab7as7j.xn--p1ai/
I also added the following code
to gk.scripts.js
- Code: Select all
$('a[href*=#]:not([href=#])').click(function() {
if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'')
|| location.hostname == this.hostname) {
var target = $(this.hash);
target = target.length ? target : $('[name=' + this.hash.slice(1) +']');
if (target.length) {
$('html,body').animate({
scrollTop: target.offset().top
}, 1000);
return false;
}
}
});
But it still doesn't scroll smoothly. Where is the problem?