<?php 
	
	session_start();

?>

<!DOCTYPE html>
<html>
<head>
	<title>Examination</title>

	<link rel="stylesheet" type="text/css" href="style.css">

</head>
<body>

	<div id="wrapper">
		<h1 id="greet">Hi! Welcome!</h1>
		<center>
			<h3 id="enterName">Please Enter Name to Start:</h3>
			<form method="POST" style="float: left; padding: 0; width: 100%;">
				<input type="text" id="name" name="name">  </input>
				<button id="startExam" name="startE">Start Test</button>
			</form>
		</center>

		<?php
			if (isset($_POST['startE'])) {

				if(!(empty($_POST['name']))) {
					$_SESSION["examineeName"] = $_POST['name'];
					header("location:exam.php");
				}else{
					echo "Field missing!";
				}
			}

		?>

	</div>

</body>
</html>