'."\n"; echo ($Assist == 'J' ? 'Judges' : 'Stewards')."\n"; echo ''."\n"; $orderby='b.brewer'; switch ($Order) { case 'ba': $orderby='b.brewer'; break; case 'bd': $orderby='b.brewer desc'; break; case 'ea': $orderby='b.email, b.brewer'; break; case 'ed': $orderby='b.email desc, b.brewer'; break; case 'na': $orderby='b.fname, b.lname, b.brewer'; break; case 'nd': $orderby='b.fname desc, b.lname desc, b.brewer'; break; } $query='select b.brewer, b.fname, b.lname, b.email, b.assist, b.bjcpid, p.ses_seq from brewer b, session_prefs p '; $query.='where b.assist="'.$Assist.'" and b.brewer=p.brewer and p.ses_seq="'.$Ses_Seq.'" order by '.$orderby; $sess_res=mysqli_query($db, $query); $cnt_sess=mysqli_num_rows($sess_res); if ($cnt_sess < 1) { echo 'No Assistance Offered'."\n"; echo '

'."\n"; } else { echo 'Assistance of '.$cnt_sess.' '.($cnt_sess > 1 ? 'people' : 'person').' is being offered.

'."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; if ($Assist == 'J') { echo ''."\n"; } if ($AskPrefs) { echo ''."\n"; echo ''."\n"; } echo ''."\n"; while ($sess_row=mysqli_fetch_assoc($sess_res)) { echo ''."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; if ($Assist == 'J') { echo ''."\n"; } if ($AskPrefs) { foreach (array(TRUE, FALSE) as $Likes) { echo ''."\n"; } } echo ''."\n"; } echo '
'."\n"; echo 'Brewer
Number
'."\n"; echo '
'."\n"; echo 'Brewer Name'."\n"; echo ''."\n"; echo 'Email Address'."\n"; echo ''."\n"; echo 'BJCP
Id'."\n"; echo '
'."\n"; echo 'Likes'."\n"; echo ''."\n"; echo 'Dislikes'."\n"; echo '
'."\n"; echo ''.$sess_row['brewer'].''."\n"; echo ''."\n"; echo safe($sess_row['fname']).' '.safe($sess_row['lname'])."\n"; echo ''."\n"; echo safe($sess_row['email'])."\n"; echo ''."\n"; echo safe($sess_row['bjcpid'])."\n"; echo ''."\n"; $query='select * from style_prefs where brewer="'.$sess_row['brewer'].'" and rank'.($Likes ? '>' : '<').'0 order by rank'.($Likes ? '' : ' desc'); $pref_res=mysqli_query($db, $query); $cnt_pref=mysqli_num_rows($pref_res); if ($cnt_pref == 0) { echo ' '."\n"; } else { echo ''."\n"; $cnt=0; while ($pref_row=mysqli_fetch_assoc($pref_res)) { ++$cnt; if ($pref_row['cat'] > 0) { ++$PrefPos; $PrefType[$PrefPos]=$pref_row['type_seq']; $PrefCat[$PrefPos]=$pref_row['cat']; $PrefSub[$PrefPos]=$pref_row['sub_cat']; } if ($cnt > 1) { echo ''."\n"; } echo ''."\n"; } while ($cnt < 3) { echo ''."\n"; echo ''."\n"; ++$cnt; } echo '
/0 ? ' onmouseover="showStyle('.$PrefPos.')" onmouseout="hideStyle()"' : '').'>'."\n"; if ($pref_row['cat'] < 1) { echo disp_cat($pref_row['type_seq']); } else { if (cntEntryCat($pref_row['type_seq'], $pref_row['cat']) > 0) { echo ''.disp_cat($pref_row['type_seq'], $pref_row['cat']).''; } else { echo disp_cat($pref_row['type_seq'], $pref_row['cat']); } if (!empty($pref_row['sub_cat'])) { if (cntEntryCat($pref_row['type_seq'], $pref_row['cat'], $pref_row['sub_cat']) > 0) { echo ''.$pref_row['sub_cat'].''; } else { echo $pref_row['sub_cat']; } } } echo '/ 
'."\n"; } echo '
'."\n"; } } ?> '."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; } ?>
0) { echo ''."\n"; echo 'Assistance Offered for Session '.safe($sess_row['ses_title'])."\n"; echo '
'."\n"; echo format_date_from_mysql($sess_row['ses_date']).(strlen($sess_row['ses_time']) > 0 ? ' '.safe($sess_row['ses_time']) : '')."\n"; echo '
'."\n"; echo '
'."\n"; if (!empty($sess_row['ses_desc']) || !empty($sess_row['ses_loc'])) { echo (!empty($sess_row['ses_desc']) ? ''.safe($sess_row['ses_desc']).'' : '')."\n";; echo ((!empty($sess_row['ses_desc']) && !empty($sess_row['ses_loc'])) ? '
' : '')."\n"; echo (!empty($sess_row['ses_loc']) ? ''.safe($sess_row['ses_loc']).'' : '')."\n"; echo '
'."\n"; } } echo '
'."\n"; echo '
'."\n"; if ($Cnt_Sess > 1) { echo 'Select Session: '."\n"; echo ''."\n"; } elseif ($Cnt_Sess == 1) { echo ''."\n"; } else { echo '

'."\n"; echo 'No Sessions Declared'."\n"; echo '

'."\n"; } echo ''."\n"; echo '
'."\n"; $PrefType=array(); $PrefCat=array(); $PrefSub=array(); $PrefPos=0; if ($Ses_Seq != 0) { BuildTable ($Ses_Seq, 'J'); BuildTable ($Ses_Seq, 'S'); } if ($AskPrefs && $PrefPos > 0) { echo ''."\n"; } ?>