include("header.php");
mysql_pconnect( "webdb0.cc.andrews.edu", "miscweb", "miscweb") or die( "Unable to connect to SQL server");
mysql_select_db("miscweb") or die ( "Unable to select database");
//
function build_table($event, $anchor){
echo "
".$event." |
";
$SQL = "SELECT name FROM rsvp_staffinstitute WHERE event = '".$event."';";
$result = mysql_query($SQL);
if(mysql_num_rows($result)>0) {
while ($row = mysql_fetch_row($result)) {
echo "";
for ($i=0; $i";
// test if this is the URL
$temp = htmlentities( $row[$i] );
if ($i == 7) {
echo "$row[$i]";
}else{
echo $temp;
}
echo "";
}
echo "
\n";
}
}else{
echo "| None yet. |
";
}
$result2 = mysql_query( "SELECT count(*) FROM rsvp_staffinstitute WHERE event = '".$event."'");
while ($row = mysql_fetch_row($result2)) {
for ($i=0; $iTotal is: ".$total." | ";
echo "
";
}
// MIKE ADD for Questions
function insert_questions(){
echo "| Questions |
";
$SQL = "SELECT name, question FROM rsvp_staffinstitute WHERE event = 'Questions';";
$result = mysql_query($SQL);
if(mysql_num_rows($result)>0) {
while ($row = mysql_fetch_row($result)) {
echo "";
for ($i=0; $i";
$temp = htmlentities( $row[$i] );
echo $temp;
echo "";
}
echo "
\n";
}
}else{
echo "| None yet. |
";
}
echo "
";
}
//********** FINISH
//
?>
| build_table("Staff Institute") ?> |
include("footer.php"); ?>