header btn link fix
This commit is contained in:
parent
d3c7149098
commit
7c13def3a2
1 changed files with 3 additions and 3 deletions
|
@ -113,10 +113,10 @@
|
|||
} else if (href) {
|
||||
var path = $(this).prop('href').split('#');
|
||||
var currentPath = window.location.origin + window.location.pathname;
|
||||
if (!path[1]) {
|
||||
window.location = href;
|
||||
} else if (currentPath == path[0]) {
|
||||
if (currentPath == path[0] && path[1]) {
|
||||
scrollToElement('#' + path[1]);
|
||||
} else {
|
||||
window.location = href;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue