Go to top of page in multi-step

When clicking Next on a multi-step form, the next page is in the same position (bottom), when the form is larger than the screen size. Is there some CSS or js to force this to go to the top of the form each time?

You can use Javascript in your pages in the pages builder.

add the following:

window.scrollTo(0, 0);
image

I used that on several of my pages in my application

2 Likes

Hey @Peter, I just tried this solution but it doesn’t seem to work for me. Does this still work for you?

@SuiteUpstairs yes - I did not notice it didn’t. Seems to be working for me. But I will keep an eye on that and let you know when I found out it doesn’t anymore.

My pages are pretty basic though, so I don’t know if it works, when there is a lot of extra CSS around.

Sometimes it take time to understand…
I just found out that you can have this code in the Javascript tab of the layout. That means this code will work for every page in this particular layout.

window.scrollTo(0, 0);

@SuiteUpstairs it still works for me. I have it now in all my layouts, and no problems with page load not being at the top of the page.