Great Neck South Class of 1972: Add Memomorium"; $message = ""; $adminPage = true; $now = gettimeofday(); if($admin && isset($_POST['addMem'])) {//Try to add $firstname = $_POST['firstname']; $lastname = $_POST['lastname']; $city = $_POST['city']; $state = $_POST['state']; $birth = $_POST['birth']; $death = $_POST['death']; $biography = nl2br($_POST['biography']); $photoFileName = ""; if(isset($_FILES['photo']) && is_uploaded_file($_FILES['photo']['tmp_name'])) { $photoFileName = $_FILES['photo']['name']; # Add the photo to the MySQL database if(move_uploaded_file($_FILES['photo']['tmp_name'], ABSOLUTE_PATH."remember/".$photoFileName)) { resizeImage($photoFileName,"remember/",200,200); } } if(!($firstname && $lastname)) { $message = "

Error adding memory. First Name, Last Name must be included.

"; } else { $query = "INSERT INTO gns_remember ( firstname ,lastname, city , state, biography, birthyear, deathyear, photo_url ) VALUES ('$firstname', '$lastname', '$city', '$state', '$biography', '$birth', '$death', '$photoFileName')"; $result = mysql_query($query); if($result) { $message = "

\" $firstname, $lastname \" Added Succesfully

"; } else { $message ="

Error Adding

"; } } } include '../inc/header.php'; echo $message; $addMemForm = "

Add a memorial:

Firstname:

Lastname:

City:

State:

Born - Died:
-

Biography:

Choose Photo:

"; // display the form on every page instance echo $addMemForm; include '../inc/footer.php'; ?>