How to create a go to previous page button

To create a go to previous page button you can use the following snippet.

Sample Javascript

<input type="submit" name="goto previous-page" id="goto-previous-page" value="Go to previous page" onClick="history.go(-1)" />

Please Share us:
Please rate this snippet

2 thoughts on “How to create a go to previous page button

Leave a Reply