1 AND strlen($_POST['sname'])>1 AND strlen($_POST['email'])>1 ) { $dbwu = "frfuncom_dbadmin"; $dbwp = "DB_Admin1"; $db = "frfuncom_charity"; $con=mysqli_connect("",$dbwu,$dbwp,$db); if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); } // Assuming there's no problem... $sql = "INSERT INTO Entries (fname, sname, email, time, pos, status, other) VALUES ('".$fname."','".$sname."','".$email."','".$time."','".$pos."',1,0)"; //echo $sql; if (!mysqli_query($con,$sql)) { die('Error: ' . mysqli_error($con)); } if ($time > 0 AND $time <15) { $day = "Saturday 20 July";} else {$day = "Friday 19 July";} $headers = 'MIME-Version: 1.0' . "\r\n"; $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n"; $headers .= 'From: tournaments@southamptonarcheryclub.org' . "\r\n"; $headers .= 'Reply-To: tournaments@southamptonarcheryclub.org' . "\r\n"; $headers .= 'X-Mailer: PHP/' . phpversion(); mail($email,"Charity slot booked", "

Hi " . $fname . "

Your slot has been booked for ".$day." at ".$dtime. " in position " . $pos . ".

Please let us know by replying to this email if you need to change your slot.

Best

Steve Ritzema
Southampton Archery Club

", $headers); echo ""; exit; } else { if (!empty($_POST['status'])){ //echo "error"; if (strlen($fname)<1) {$fnamee=1;} if (strlen($sname)<1) {$snamee=1;} if (strlen($email)<1) {$emaile=1;} $err = "

Please correct missing information below."; } } ?> Charity Event

The details below will only be used to send a confirmation for your slot - so you know which one you've chosen, and you can add it to your calendar. If you need to update your slot, please reach out to tournaments@southamptonarcherclub.org.
Warning: Undefined variable $err in /home/frfuncom/public_html/charity/submit.php on line 96

Slot At
Warning: Undefined variable $dtime in /home/frfuncom/public_html/charity/submit.php on line 108
in position
Warning: Undefined variable $pos in /home/frfuncom/public_html/charity/submit.php on line 108
First Name >
Family Name >
Email >
(only used if there's a problem with your slot, deleted after the event)
(4 secs)