<?php session_start();
if($_SESSION){
?>


<?php

     $conn = new mysqli("localhost","root","","event");
	$name = ($_POST['name']);
	
	


	function test_input($data) {
  $data = trim($data);
  $data = stripslashes($data);
  $data = htmlspecialchars($data);
  $data = mysql_real_escape_string($data);
  return $data;
}

	//$insert = "INSERT INTO `ragistar`(`id`, `name`, `age`, `gender`, `email`, `salary`, `qualification`) VALUES ([$fname],[$fage],

	//[$fgender],[$fEmail],[$fsalary],[$fQualification])";
	
	
	$insert = "insert into music_event_eqi1 (eqi1)  
	values ('".$name."')";

	$confirmation = mysqli_query($conn,$insert);
		



			if($confirmation){
				header('Location: music_eqi1_display.php');
			
			}
		
	else{
		
			header('Location: wedding plarners.php');
	}
	


?>
<?php
  }
  else{
    echo "<script>
   alert('You have to  login first...!');
   window.location.href='event2.php';
   </script>";
  }
  
?>