Registration Form

[insert_php]
session_start();
include(‘softball-common.php’);

$con = db_connect();

$countConfirmTeamssql = ‘SELECT COUNT(ID) from teams WHERE Confirm is not null AND Del is null’;
$countConfirmTeams = mysql_query($countConfirmTeamssql);
$countApprovalTeamssql = ‘SELECT COUNT(ID) from teams WHERE Confirm is null AND Del is null’;
$countApproval = mysql_query($countApprovalTeamssql);

session_register ( “ADDTeamName” );
session_register ( “ADDServiceName” );
session_register ( “ADDContactName” );
session_register ( “ADDEMail” );
session_register ( “ADDPriContact” );
session_register ( “ADDSecContact” );
session_register ( “ADDTournContact” );
session_register ( “ADDComments” );
//session_register ( “ADDVote” );

if (isset ($_POST[‘destroysess’])) {
session_destroy();
header(‘Location:softball-register.php’);
} else {}

$errors = array();

if (isset($_POST[‘submit’])) {
// validate
if (strlen($_POST[‘TeamName’]) <= 0) $errors['TeamName'] = "Please enter a Team Name!"; if (strlen($_POST['ServiceName']) <= 0) $errors['ServiceName'] = "Please enter a Service Name!"; if (strlen($_POST['ContactName']) <= 0) $errors['ContactName'] = "Please enter a Contact Name!"; if (strlen($_POST['EMail']) <= 0) $errors['EMail'] = "Please enter an E-Mail Address!"; if (strlen($_POST['PriContact']) <= 0) $errors['PriContact'] = "Please enter a Contact Number!"; if (strlen($_POST['TournContact']) <= 0) $errors['TournContact'] = "Please enter a Contact Number!"; //if (strlen($_POST['Vote']) <= 0) // $errors['Vote'] = "Please PLACE your Vote!"; // check if confirmation matches if ($_POST['EMail'] != $_POST['ConfirmEMail']) $errors['ConfirmEMail'] = "E-Mail confirmation does not match!"; if (count($errors) <= 0) { $_SESSION['ADDTeamName'] = $_POST['TeamName']; $_SESSION['ADDServiceName'] = $_POST['ServiceName']; $_SESSION['ADDContactName'] = $_POST['ContactName']; $_SESSION['ADDEMail'] = $_POST['EMail']; $_SESSION['ADDPriContact'] = $_POST['PriContact']; $_SESSION['ADDSecContact'] = $_POST['SecContact']; $_SESSION['ADDTournContact'] = $_POST['TournContact']; $_SESSION['ADDComments'] = $_POST['Comments']; //$_SESSION['ADDVote'] = $_POST['Vote']; $Confirm = "T"; } else { $errors['Exist'] = "There are ERRORS on the Registration Form!"; } } [/insert_php]

[insert_php] $ConfirmResult = mysql_fetch_array($countConfirmTeams); echo $ConfirmResult[‘COUNT(ID)’]; [/insert_php] of 24 spots are Currently APPROVED
There are [insert_php] $ApprovalResult = mysql_fetch_array($countApproval); echo $ApprovalResult[‘COUNT(ID)’]; [/insert_php] applications Pending approval.

[insert_php] if (empty ($Confirm)) { [/insert_php]

REGISTRATION IS NOW OPEN!

NOTE: Any entries received over the 24 team
threshold will be notified by the tournament organizers and put on a waiting list if requested.

E-mail is the preferred method of contact and thus is required by this form.
If you yourself are unable to supply an e-mail address, please attempt to
find someone that you can use as an e-mail contact and have them forward you
any information that is sent out by the Tournament Organizers.

STEP 1 of 3

[insert_php] errorecho($errors, ‘Exist’);[/insert_php]

[insert_php] } else { [/insert_php]

STEP 2 of 3

Please confirm the details below.

[insert_php] } [/insert_php]

[insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] } else { [/insert_php]

[insert_php] } [/insert_php]

[insert_php] } else {
print $_SESSION[‘ADDTeamName’];
} [/insert_php]

[insert_php] } else {
print $_SESSION[‘ADDServiceName’];
} [/insert_php]

[insert_php] } else {
print $_SESSION[‘ADDContactName’];
} [/insert_php]

[insert_php] } else {
print $_SESSION[‘ADDEMail’];
} [/insert_php]

[insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] } [/insert_php]

[insert_php] } else {
print $_SESSION[‘ADDPriContact’];
} [/insert_php]

[insert_php] } else {
print $_SESSION[‘ADDSecContact’];
} [/insert_php]

[insert_php] } else {
print $_SESSION[‘ADDTournContact’];
} [/insert_php]

[insert_php] } else {
print $_SESSION[‘ADDComments’];
} [/insert_php]

Team Name:
(may be changed based on space on schedule)
[insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] errorecho($errors, ‘TeamName’);[/insert_php]
Service/Association Represented: [insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] errorecho($errors, ‘ServiceName’);[/insert_php]
Contact Name: [insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] errorecho($errors, ‘ContactName’);[/insert_php]
E-Mail Address: [insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] errorecho($errors, ‘EMail’);[/insert_php]
Confirm (Re-Type) E-Mail Address:
[insert_php] errorecho($errors, ‘ConfirmEMail’);[/insert_php]
Primary Contact Number: [insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] errorecho($errors, ‘PriContact’);[/insert_php]
Secondary Contact Number: [insert_php] if (empty ($Confirm)) { [/insert_php]
Tournament Weekend Contact Number:
(in case of last minute required contact)
[insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] errorecho($errors, ‘TournContact’);[/insert_php]
Additional Comments or Questions: [insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] if (empty ($Confirm)) { [/insert_php]

[insert_php] } else { [/insert_php]

[insert_php] } [/insert_php]