3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php if (isset($_GET['item'])) { $cart_item = $_GET['item']; } ?> <!doctype html> <html lang="en"> <head> <meta charset="utf-8"> </head> <body> <form method="post" action=""/> <input type="hidden" name="item"> <input type="submit" value="Yes, Add to Cart"> </form> echo $item; </body> </html>
Output for 4.3.0 - 5.6.28, hhvm-3.12.0, 7.0.0 - 7.1.0
<!doctype html> <html lang="en"> <head> <meta charset="utf-8"> </head> <body> <form method="post" action=""/> <input type="hidden" name="item"> <input type="submit" value="Yes, Add to Cart"> </form> echo $item; </body> </html>
Output for hhvm-3.10.0

Process exited with code 153.