Biocomplexity VI Workshop Data
';
if(isset($_GET['f']) && $_GET['f'] == 'basic') {
$updated = mysql_num_rows(mysql_query("SELECT UserID FROM $table WHERE ModDate >= '2004-04-27 00:00:00'"));
$banquet = array();
$banquet['y'] = mysql_num_rows(mysql_query("SELECT Banquet FROM $table WHERE Banquet = 'y'"));
$banquet['n'] = mysql_num_rows(mysql_query("SELECT Banquet FROM $table WHERE Banquet = 'n'"));
$banquet['un'] = $total - ($banquet['y'] + $banquet['n']);
$ppos = array();
$ppos['faculty'] = mysql_num_rows(mysql_query("SELECT ParticipantPosition FROM $table WHERE ParticipantPosition = 'faculty'"));
$ppos['postdoc'] = mysql_num_rows(mysql_query("SELECT ParticipantPosition FROM $table WHERE ParticipantPosition = 'postdoc'"));
$ppos['gradstudent'] = mysql_num_rows(mysql_query("SELECT ParticipantPosition FROM $table WHERE ParticipantPosition = 'gradstudent'"));
$ppos['other'] = mysql_num_rows(mysql_query("SELECT ParticipantPosition FROM $table WHERE ParticipantPosition = 'other'"));
$ppos['un'] = $total - ($ppos['faculty'] + $ppos['postdoc'] + $ppos['gradstudent'] + $ppos['other']);
$sex = array();
$sex['m'] = mysql_num_rows(mysql_query("SELECT Sex FROM $table WHERE Sex = 'M'"));
$sex['f'] = mysql_num_rows(mysql_query("SELECT Sex FROM $table WHERE Sex = 'F'"));
$sex['un'] = $total - ($sex['m'] + $sex['f']);
$posters = array();
$posters['reg'] = mysql_num_rows(mysql_query("SELECT Poster FROM $table WHERE Poster = 'y'"));
$posters['recvd'] = mysql_num_rows(mysql_query("SELECT semester FROM seminars WHERE semester = 'ws_bio_vi_pp'"));
$report = 'Basic:
' .
$updated . ' of ' . $total . ' have updated their registration since 27 April.Banquet:
' .
$banquet['y'] . ' said they will attend;' . $banquet['n'] . ' said they will not attend;
' . $banquet['un'] . ' gave no response.
Posters Presentations
' .
$posters['reg'] . ' said that they would present a poster;We have received ' . $posters['recvd'] . ' abstracts.
Of the participants:
' .
$ppos['faculty'] . ' are faculty;' . $ppos['postdoc'] . ' are post-docs;
' . $ppos['gradstudent'] . ' are grad students;
' . $ppos['other'] . ' are neither a faculty member, post-doc, nor a grad student;
' . $ppos['un'] . ' gave no response.
' . $sex['m'] . ' are male;
' . $sex['f'] . ' are female;
' . $sex['un'] . ' gave no response'; echo $report; } // otherwise elseif (isset($_GET['f'])) { // determine the mysql query $input = $_GET['f']; if($input == 'food') { $sql = mysql_query("SELECT FName, MName, LName, Email, FoodPref AS FData FROM wsreg WHERE (FoodPref NOT LIKE 'none%' && FoodPref NOT LIKE 'no' && FoodPref != '') ORDER BY LName ASC;"); echo '
Food Preferences
';
}
elseif($input == 'accom') {
$sql = mysql_query("SELECT FName, MName, LName, Email, OtherNeeds AS FData FROM wsreg WHERE (OtherNeeds NOT LIKE 'none%' && OtherNeeds NOT LIKE 'no%' && OtherNeeds != '') ORDER BY LName ASC;");
echo 'Special Needs & Accomodations
';
}
elseif($input == 'tplan') {
$sql = mysql_query("SELECT FName, MName, LName, Email, TravelPlan AS FData FROM wsreg WHERE (TravelPlan NOT LIKE 'none' && TravelPlan NOT LIKE 'no' && TravelPlan != '') ORDER BY LName ASC;");
echo 'Travel Plans
';
}
else {
die('No function specified.');
}
$count = mysql_num_rows($sql);
echo '' . $count . ' responses below; ' . ($total-$count) . ' did not respond or were filtered out because they indicated \'none\' when responding.'; // print data while ($data = mysql_fetch_array($sql)) { // name $name = ''; if(@$data['Prefix']) { $name .= stripslashes($data['Prefix']) . ' '; } if(@$data['FName']) { $name .= stripslashes($data['FName']) . ' '; } if(@$data['MName']) { $name .= stripslashes($data['MName']) . ' '; } if(@$data['LName']) { $name .= stripslashes($data['LName']); } if(@$data['Suffix']) { $name .= ' ' . stripslashes($data['Suffix']); } // ##################### echo '' . $name . ' / ' . $data['Email'] . '
' . nl2br($data['FData']) . '
'; } // end print data } // end basic report! else { echo 'No function specified.'; } echo '
Results as of: ' . date("d M Y H:i") . '