3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $var = 'PHP Tutorial'; ?> <!DOCTYPE html> <html> <head> <title><?php echo $var; ?></title> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> </head> <body> <form method= 'POST'> <h2>Please input your name: </h2> <input type='text' name='name'> <input type='submit' value = "Submit Name"> </form> <?php $name = $_POST['name']; echo "<h3> Hello $name </h3>"; ?> </body> </html>
Output for 5.3.0 - 7.1.0
<!DOCTYPE html> <html> <head> <title>PHP Tutorial</title> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> </head> <body> <form method= 'POST'> <h2>Please input your name: </h2> <input type='text' name='name'> <input type='submit' value = "Submit Name"> </form> Notice: Undefined index: name in /in/EI2q4 on line 16 <h3> Hello </h3> </body> </html>
Output for 4.3.0 - 5.2.17
<!DOCTYPE html> <html> <head> <title>PHP Tutorial</title> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> </head> <body> <form method= 'POST'> <h2>Please input your name: </h2> <input type='text' name='name'> <input type='submit' value = "Submit Name"> </form> Notice: Undefined index: name in /in/EI2q4 on line 16 <h3> Hello </h3> </body> </html>