if ($_POST) {
$name = $_POST['name'];
$surname = $_POST['surname'];
$message = $_POST['message'];
$sql = "INSERT INTO `comments` (`name`, `surname`, `message`) VALUES(:name, :surname, :message)";
$query = $conn->prepare($sql);
$query->execute(['name' => $name, 'surname' => $surname, 'message' => $message]);
}