Error in the SCROLL function inside the OnClick

1

Good afternoon Personal, a week or so a customer came complaining that his site link was not working and I could not understand why, because the site was delivered working, it was a link that simply rolled the page . This week I noticed that the same type of link stopped working on other sites of mine, and it's a scroll function that I use for a long time, and it's presenting an error that I still can not decipher, can someone give me a help ?

I'm putting in the images below the link code that calls the function by onclick, the error and also the js function I'm using.

    
asked by anonymous 10.10.2017 / 15:44

1 answer

1

As far as I read about this, the scroll function being called does not correspond to its own function, but to the function window.scroll , which receives different parameters, causing this error in chrome.

Try renaming your function and make sure your issue is resolved.

By doing a quick test here declaring a function with another name in the console and changing the onclick to call this function, the scrolling worked perfectly.

    
10.10.2017 / 16:01