Support » Plugin: Easy Smooth Scroll Links » [Plugin: Easy Smooth Scroll Links] Update the .js file

  • froozeify



    When we click on an anchor the adress bar show :

    if you want to hide the #anchor in the adress bar, you can change the .js file to

    [ Moderator Note: Please post code or markup snippets between backticks or use the code button not blockqoute. ]

        $('a[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) {
        var targetOffset = $target.offset().top;
        $('html,body').animate({scrollTop: targetOffset}, 1000);
        return false;

    And now the adress display in the bar when you click on an anchor is :

    the #anchor disappears.

    If you want an example don’t hesitate to ask me.

    [ Signature moderated. ]

Viewing 1 replies (of 1 total)
  • Hi,

    I’ve tried to replace all the code in the .js file for your code, in order to remove the # from the URL, but it does not work.

    Am I missing something?

    Thanks in advance for your response.

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Easy Smooth Scroll Links] Update the .js file’ is closed to new replies.