<?php
include_once 'connection.php';
if(isset($_POST['submit']))
{	 
    $initial = $_POST['initial'];
	 $first_name = $_POST['first_name'];
	 $middle = $_POST['middle'];
	 $last_name = $_POST['last_name'];
	//  $created_at= date("Y-m-d H:i:s");
	
	 $sql = "INSERT INTO registration(initial,first_name,middle,last_name)
	 VALUES ('$initial','$first_name','$middle','$last_name')";
	 if (mysqli_query($conn, $sql)) {
		
	 } else {
		echo "Error: " . $sql . "
" . mysqli_error($conn);
	 }
	 mysqli_close($conn);
	 header("Location:index.php");
}
?>