How to setup back button?

How do we setup a back button to return visitors to the previous section? I have a link button located somewhere in the middle of the website, and when visitors clicked the button they are redirected to another page. We want them to return to the middle section of the page when they hit back button from the other page.

PS: I tried putting an “id” to the section but it slides down from top to middle, we want them to instantly go back without the page slide.

Put this in the URL box

`javascript:history.back();

http://sandbox-903b9c.webflow.io/back-link

15 Likes

I tried : http://i.imgur.com/Nk9mkg1.png but i get blank page

1 Like

You must type it out exactly the same, character for character. If you cannot do it, then copy and paste the above. No http:// in front!

No, webflow automatically add http on the url box even though I add the code “javascript:history.back();”

Have you tried this in webflow site?

http://sandbox-903b9c.webflow.io/back-link

Look at my code carefully again. You are missing the first character.

1 Like

Ok I see, It works now I should not click the field when pasting so that it would not add http. Thanks!

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.