How to Refresh the Page without losing what is in the $_POST['x']?

Asked

Viewed 28 times

1

Hello I am using this method to update the page:

header("Refresh: 0");

but wouldn’t want to miss what’s in the $_POST...

How to proceed in this situation?

  • http://php.net/manual/en/reserved.variables.session.php ou http://php.net/manual/en/features.cookies.php

  • Saved somewhere. Database, cookies, localStorage

  • 1

    I think the simplest way is to make a $_SESSION["post"] = $_POST;

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.