require ("/home/ncacaa/config.php"); require ("variables.php"); if ($_POST[action] != 'Register') { include ("registration_form.php"); exit; } elseif (isset ($_POST[email]) && ($_POST[email] != '') && isset ($_POST[realname]) && ($_POST[realname] != '') && isset ($_POST[county]) && ($_POST[county] != '') && isset ($_POST[phone]) && ($_POST[phone] != '') && (($_POST[members] + $_POST[children]) >= 1)) /* removed as not needed isset ($_POST[address]) && ($_POST[address] != '') && isset ($_POST[city]) && ($_POST[city] != '') && isset ($_POST[zip]) && ($_POST[zip] != '') && */ { // All required info is passed - continue use_ncacaa(); // clean up rest of the variables foreach ($_POST as $key => $value) { $$key = $value; } $party_cnt = ($_POST[members] + $_POST[children]); // error checking $real_name = htmlentities (trim ($real_name), ENT_QUOTES); $county = htmlentities (trim ($county), ENT_QUOTES); $address = htmlentities (trim ($address), ENT_QUOTES); $city = trim ($city); $zip = trim ($zip); $phone = trim ($phone); $spouse = htmlentities (trim ($spouse_name), ENT_QUOTES); $child_name_age = htmlentities (trim ($child_name_age), ENT_QUOTES); $comments = htmlentities (trim ($comments), ENT_QUOTES); $total_amt = ($members * $member_cost ) + ($children * $child_cost) ; $today = getdate (); $today_epoch = mktime(0,0,0,$today[mon], $today[mday], $today[year]); if ($today_epoch > $late_date_epoch) { $total_amt += $late_fee; } else { $late_fee = 0; } $sql = "INSERT INTO registration2008 (realname, email, county, phone, spouse_name, child_name_age, members, children, total_amt, late_fee, comments, date) VALUES ('$realname', '$email', '$county', '$phone', '$spouse_name', '$child_name_age', '$members', '$children', '$total_amt', '$late_fee', '$comments', NOW()) "; $result = mysql_query ($sql) or die (mysql_error_message()); $id = mysql_insert_id (); print(" \n"); print("
\n"); print("
Spouse: " . stripslashes ($spouse_name) . " | \n");
print ("
Guests/Children: " . stripslashes ($child_name_age) . " | \n");
print ("
County: " . stripslashes ($county) . " | \n");
print ("
" . stripslashes ($address) . " | \n");
print ("
$phone | \n");
print ("
| Fees | \n"); print ("|
|---|---|
| Member & Guest Registration | \n"); print ("$" . ($members * $member_cost) . " | \n"); print ("
| Spouse & Children Attending Youth Activity | \n"); print ("$" . ($children * $child_cost) . " | \n"); print ("
| Late Fee | \n"); print ("$" . ($late_fee) . " | \n"); print ("
| Total | \n"); print ("\$" . number_format ($total_amt, 0). " | \n"); print ("
| Comments: | \n"); print ("" . stripslashes ($comments) . " | \n"); print ("
|---|
Thank you for registering for the NCACAA Annual Meeting. Please verify that all the information is correct. If you need to make changes, please contact Tammara Cole - (828)554-6936
\n"); print("Print this page and mail it, along with a check made payable to NCACAA, to:
\n");
print("
Tammara Cole
NCCES
Cherokee Reservation Center
P.O. Box 456
Cherokee, NC 28719
If you have any problems with the registration process, contact John Dorner.
\n");
print(" \n");
print(" \n");
}
else
{
// not all required info passed
print(" \n");
print("
Please go back and make sure you completed the form. If you feel there is an error or would like to make a change, please contact John Dorner.
\n"); print ("