I want a smooth horizontal scrolling to go to the top of a page when clicking on links. It links a few rows down in an iPhone, so I would need a code that makes you end up on top.
It links to the right place in an iPhone but the address bar put in the way

This only happens after the page has fully loaded, and then links it with no smooth scrolling, then directly to a place without smooth scrolling.

I have tried this in my javascript:
Code:
window.scrollTo(0,0);