示例#1
0
function send_admin_email()
{
    $emailAddress = REG_EMAIL;
    $VerificationLink = DOMAIN_NAME . '/manageregistrations.php';
    $fn = format_uppercase_text($_POST['firstname']);
    $ln = format_uppercase_text($_POST['lastname']);
    $emailBody = $fn . ' ' . $ln . ' has just registered for TCSHL league membership.  Click on the following link to approve registration: ';
    $emailBody .= $VerificationLink;
    $headers = 'From: ' . VERIFICATION_EMAIL_SENDER;
    //Send email
    mail($emailAddress, VERIFICATION_EMAIL_SUBJECT, $emailBody, $headers);
}
示例#2
0
 private function formProcess()
 {
     if (isset($_POST['firstname']) && $_POST['firstname']) {
         $this->set_fname(format_uppercase_text($_POST['firstname']));
     }
     // Required
     if (isset($_POST['lastname']) && $_POST['lastname']) {
         $this->set_lname(format_uppercase_text($_POST['lastname']));
     }
     // Required
     if (isset($_POST['addressOne']) && $_POST['addressOne']) {
         $this->set_addressOne(format_text($_POST['addressOne']));
     }
     // Required
     if (isset($_POST['addressTwo']) && $_POST['addressTwo']) {
         $this->set_addressTwo(format_text($_POST['addressTwo']));
     } else {
         $this->set_addressTwo("");
     }
     if (isset($_POST['city']) && $_POST['city']) {
         $this->set_city(format_uppercase_text($_POST['city']));
     }
     //Required
     if (isset($_POST['state']) && $_POST['state']) {
         $this->set_state(format_text($_POST['state']));
     }
     //Required
     if (isset($_POST['postalCode']) && $_POST['postalCode']) {
         $this->set_postalcode(format_text($_POST['postalCode']));
     }
     //Required
     if (isset($_POST['email']) && $_POST['email']) {
         $this->set_email(format_text(strtolower($_POST['email'])));
     } else {
         $this->set_email("");
     }
     if (isset($_POST['homePhone']) && $_POST['homePhone']) {
         $this->set_homephone(format_text($_POST['homePhone']));
     } else {
         $this->set_homephone("");
     }
     if (isset($_POST['workPhone']) && $_POST['workPhone']) {
         $this->set_workphone(format_text($_POST['workPhone']));
     } else {
         $this->set_workphone("");
     }
     if (isset($_POST['cellPhone']) && $_POST['cellPhone']) {
         $this->set_cellphone(format_text($_POST['cellPhone']));
     } else {
         $this->set_cellphone("");
     }
     /**
     if (isset($_POST['goalie']) && $_POST['goalie'] == "on") {
     	$goalie = "Y";
     } else {
     	$goalie = "N";
     }
     if (isset($_POST['defense']) && $_POST['defense'] == "on") {
     	$defense = "Y";
     } else {
     	$defense = "N";
     }
     if (isset($_POST['center']) && $_POST['center'] == "on") {
     	$center = "Y";
     } else {
     	$center = "N";
     }
     if (isset($_POST['wing']) && $_POST['wing'] == "on") {
     	$wing = "Y";
     } else {
     	$wing = "N";
     }
     */
     if (isset($_POST['position']) && $_POST['position']) {
         $this->set_position($_POST['position']);
     }
     //Required
     if (isset($_POST['jerseySize']) && $_POST['jerseySize']) {
         $this->set_jerseysize($_POST['jerseySize']);
     }
     //Required
     if (isset($_POST['jerseyNumChoiceOne']) && $_POST['jerseyNumChoiceOne'] || $_POST['jerseyNumChoiceOne'] == 0) {
         $this->set_jerseyNumberOne($_POST['jerseyNumChoiceOne']);
     }
     //Required
     if (isset($_POST['jerseyNumChoiceTwo']) && $_POST['jerseyNumChoiceTwo'] || $_POST['jerseyNumChoiceTwo'] == 0) {
         $this->set_jerseyNumberTwo($_POST['jerseyNumChoiceTwo']);
     }
     //Required
     if (isset($_POST['jerseyNumChoiceThree']) && $_POST['jerseyNumChoiceThree'] || $_POST['jerseyNumChoiceThree'] == 0) {
         $this->set_jerseyNumberThree($_POST['jerseyNumChoiceThree']);
     }
     //Required
     if (isset($_POST['travelWith']) && $_POST['travelWith']) {
         $this->set_travelingWithWho(format_text($_POST['travelWith']));
     } else {
         $this->set_travelingWithWho("");
     }
     if (isset($_POST['additionalNotes']) && $_POST['additionalNotes']) {
         $this->set_notes(format_text($_POST['additionalNotes']));
     } else {
         $this->set_notes("");
     }
     if (isset($_POST['skillLevel']) && $_POST['skillLevel']) {
         $this->set_skilllevel($_POST['skillLevel']);
     }
     //Required
     if (isset($_POST['willSub']) && $_POST['willSub'] == "Y") {
         $this->set_wantToSub(1);
         if (isset($_POST['sunSub']) && $_POST['sunSub'] == "on") {
             $this->set_subSunday(1);
         } else {
             $this->set_subSunday(0);
         }
         if (isset($_POST['monSub']) && $_POST['monSub'] == "on") {
             $this->set_subMonday(1);
         } else {
             $this->set_subMonday(0);
         }
         if (isset($_POST['tueSub']) && $_POST['tueSub'] == "on") {
             $this->set_subTuesday(1);
         } else {
             $this->set_subTuesday(0);
         }
         if (isset($_POST['wedSub']) && $_POST['wedSub'] == "on") {
             $this->set_subWednesday(1);
         } else {
             $this->set_subWednesday(0);
         }
         if (isset($_POST['thuSub']) && $_POST['thuSub'] == "on") {
             $this->set_subThursday(1);
         } else {
             $this->set_subThursday(0);
         }
         if (isset($_POST['friSub']) && $_POST['friSub'] == "on") {
             $this->set_subFriday(1);
         } else {
             $this->set_subFriday(0);
         }
         if (isset($_POST['satSub']) && $_POST['satSub'] == "on") {
             $this->set_subSaturday(1);
         } else {
             $this->set_subSaturday(0);
         }
     } else {
         $this->set_wantToSub(0);
         $this->set_subSunday(0);
         $this->set_subMonday(0);
         $this->set_subTuesday(0);
         $this->set_subWednesday(0);
         $this->set_subThursday(0);
         $this->set_subFriday(0);
         $this->set_subSaturday(0);
     }
     if (isset($_POST['teamRep']) && $_POST['teamRep'] == "Y") {
         $this->set_wantToBeATeamRep(1);
     } else {
         $this->set_wantToBeATeamRep(0);
     }
     if (isset($_POST['referee']) && $_POST['referee'] == "Y") {
         $this->set_wantToBeARef(1);
     } else {
         $this->set_wantToBeARef(0);
     }
     if (isset($_POST['paymentPlan']) && $_POST['paymentPlan'] == "1") {
         $this->set_paymentPlan(1);
     } else {
         if (isset($_POST['paymentPlan']) && $_POST['paymentPlan'] == "2") {
             $this->set_paymentPlan(2);
         } else {
             if (isset($_POST['paymentPlan']) && $_POST['paymentPlan'] == "3") {
                 $this->set_paymentPlan(3);
             } else {
                 if (isset($_POST['paymentPlan']) && $_POST['paymentPlan'] == "4") {
                     $this->set_paymentPlan(4);
                 } else {
                     if (isset($_POST['paymentPlan']) && $_POST['paymentPlan'] == "5") {
                         $this->set_paymentPlan(1);
                     }
                 }
             }
         }
     }
     #Setup the positions comma separated value
     /** - This is no longer needed.  We set positions directly above.
     		$positions = "";		
     		if($goalie == "Y") {
     			if($defense == "Y" || $center == "Y" || $wing == "Y") {
     				$positions .= "G, ";
     			} else {
     				$positions .= "G";
     			}
     		}
     		if($defense == "Y") {
     			if($center == "Y" || $wing == "Y") {
     				$positions .= "D, ";
     			} else {
     				$positions .= "D";
     			}
     		}
     		if($center == "Y") {
     			if($wing == "Y") {
     				$positions .= "C, ";
     			} else {
     				$positions .= "C";
     			}
     		}
     		if($wing == "Y") {
     			$positions .= "W";
     		}
     		$this->set_position($positions);
     		*/
     if (isset($_POST['drilLeague']) && $_POST['drilLeague']) {
         $this->set_drilLeague($_POST['drilLeague']);
     }
     //Required
     if (isset($_POST['payToday']) && $_POST['payToday'] == "on") {
         $this->set_payToday(1);
     } else {
         $this->set_payToday(0);
     }
     if (isset($_POST['usaHockeyMembership']) && $_POST['usaHockeyMembership']) {
         $this->set_usaHockeyMembership(format_trim(strtoupper($_POST['usaHockeyMembership'])));
     } else {
         $this->set_usaHockeyMembership("");
     }
 }
示例#3
0
 private function formProcess()
 {
     $this->set_boardMemberFirstName(format_uppercase_text($_POST['boardMemberFirstName']));
     $this->set_boardMemberLastName(format_uppercase_text($_POST['boardMemberLastName']));
     $this->set_boardMemberEmail($_POST['boardMemberEmail']);
     $this->set_boardMemberHomePhone($_POST['boardMemberHomePhone']);
     $this->set_boardMemberWorkPhone($_POST['boardMemberWorkPhone']);
     $this->set_boardMemberCellPhone($_POST['boardMemberCellPhone']);
     $this->set_boardMemberDuties($_POST['boardMemberDuties']);
     if ($_FILES['boardMemberImage']['size'] > 0 && ($_FILES['boardMemberImage']['type'] == 'image/jpeg' || $_FILES['boardMemberImage']['type'] == 'image/gif')) {
         $this->formImageProcess();
     } else {
         $this->boardMemberImageWidth = 0;
         $this->boardMemberImageHeight = 0;
     }
 }
示例#4
0
function send_admin_email()
{
    require_once 'com/tcshl/mail/Mail.php';
    $emailAddress = SITEREG_EMAIL;
    $VerificationLink = DOMAIN_NAME . '/account.php';
    $fn = format_uppercase_text($_POST['firstname']);
    $ln = format_uppercase_text($_POST['lastname']);
    $em = format_trim(strtolower($_POST['email']));
    $emailBody = $fn . ' ' . $ln . '(' . $em . ') has just registered for TCSHL site membership.  Click on the following link if you need to give this account admin privileges: ';
    $emailBody .= $VerificationLink;
    //$sender,$recipients,$subject,$body
    $Mail = new Mail(VERIFICATION_EMAIL_SENDER, $emailAddress, VERIFICATION_EMAIL_SUBJECT, $emailBody);
    $Mail->sendMail();
}