There is a view page with views_infinite_scroll paging. This page is being used for list products.

Everything is working as I needed, but the problem is:

Suppose I'm on 5th page(Note: with scroll pagination) and I click on product to go to it's detail page, the detail page have a link to return back to the product listing page. So, when user clicks on "Back to previous Page" link on product detail page, it should display the 5th page with exact page view position.

Please help how should we achieve this?

Thanks In Advance

1 Answer 1


I know this answer seems to be (might be) a bad solution but it works. Use the code window.history.back() for "Back to previous Page" link like follows

<input type="button" value="Back to previous Page" onclick="window.history.back()" />


<a href="#" onclick="window.history.back()"> Back to previous Page </a>

As far as I know this is browsers default behavior. So it works.

I've tested it and working on latest version of all major browsers.

Hope it helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.