3v4l.org

run code in 300+ PHP versions simultaneously
<?php $nameErr= $surnameErr = ""; $name= $surname = ""; $errors= ""; if ($_SERVER["REQUEST_METHOD"] == "POST") { if(empty($_POST['customer_name'])){ $errors[] = "Please provide with real human being name"; } if(count($errors)>0) $errors = implode('<br />',$errors); } function test_input($data) { $data = trim($data); $data = stripslashes($data); $data = htmlspecialchars($data); return $data; } ?>

preferences:
34.1 ms | 402 KiB | 5 Q