F
F
Frada_margan2020-07-16 15:42:28
Laravel
Frada_margan, 2020-07-16 15:42:28

How to return to the desired position on the page when the back button is clicked in Laravel?

Good afternoon,
I have a table of products, 20 items are displayed on one page, all products are configured in pagination.
When I go to the second page and select a product to change after changing, I press back to return me to the first page. How to make it so that it would return back to the page from which I select the product to change. That is, if I was on the 10th page and went there, changed the product after clicking on the back button, I was returned to the same 10th page.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Maxim, 2020-07-16
@myks92

It is necessary that the current page is taken from the GET request and the ?page=2 parameter

S
Sanes, 2020-07-16
@Sanes

And if so?

<a onclick="javascript:history.back(); return false;">Назад</a>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question