Created
February 12, 2014 09:38
-
-
Save theand/8952523 to your computer and use it in GitHub Desktop.
Post/Redirect/Get example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| if( $_POST["key"] ){ | |
| var_dump($_POST["key"]); | |
| header("Location: " . $_SERVER['REQUEST_URI']); | |
| exit(); | |
| } | |
| ?> | |
| <form method="post" action=""> | |
| <label for="inputKey">Key</label> | |
| <input type="text" name="key" id="inputKey" /> | |
| <input type="submit" value="SUBMIT" /> | |
| </form> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment