Guest User

Untitled

a guest
Jun 25th, 2018
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. <?php
  2. session_start()
  3. if ($_POST['var'] == 1337)
  4. {
  5. $_SESSION['var'] = $_POST['var'];
  6. echo "You pushed the button and the value is ", $_POST['var'];
  7. }
  8. else
  9. {
  10. echo "You pushed a button and I got nothing!";
  11. }
  12.  
  13. ?>
  14.  
  15. <html>
  16. <body>
  17. <form action="" method="POST">
  18. <input type="hidden" name="var" value="1337">
  19. <input type="submit" value="GO">
  20. </form>
  21. </body>
  22. </html>
Add Comment
Please, Sign In to add comment