N
N
Nikolino2018-10-31 21:11:52
Laravel
Nikolino, 2018-10-31 21:11:52

How to remove flash message on browser back button?

After saving the form, we transfer it somewhere with ->with('status', 'Saved!');
But if after that you go somewhere, and press "back" in the browser, then the message "Saved" pops up again.
Most likely it is the browser that caches the page along with the message.
Has anyone experienced this? How to fix it so that it does not pop up the second and subsequent times when moving back / forward in the browser.
It's not even about back / forward in the browser, but if we follow the link from the page to where the message was shown, then it is shown again.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question