Viewing Schedule for:
" . $list->name . " " . $list->year . ", " . $list->program . ""; } } ?>

0){ while($agenda = mysql_fetch_object($agendas)){ // Loop-a-rooni! for($x = 1; $x <= 8; $x++){ #if($agenda->{"topic".$x}){ // Process Date: if( ($agenda->{"datetime".$x."_start"} != "0000-00-00 00:00:00") && ($agenda->{"datetime".$x."_end"} != "0000-00-00 00:00:00") ){ // Break 'em up $start = explode(" ",$agenda->{"datetime".$x."_start"}); $end = explode(" ",$agenda->{"datetime".$x."_end"}); // If Start/End Dates Are same (single date) if($start[0] == $end[0]){ $date = dateformat($start[0], "F jS Y"); // Start date if( ($start[1] == $end[1]) && (substr($start[1],-2) != "01") ){$time = " ".timeformat($start[1],0);} // If Start/End time are the same, show start time. if(substr($start[1],-2) == "01"){$time = "";} // If No Start time, assume full-day event. if($start[1] != $end[1]){$time = " ".timeformat($start[1],0)." - ".timeformat($end[1],0);} // If different, show range if( (substr($start[1],-2) != "01") && (substr($end[1],-2) == "01") ){$time = " ".timeformat($start[1],0);} // If Start Time, no end time, show start time. $datedisplay = "$date$time"; } // If Start/End Dates Are Different (date range) if($start[0] != $end[0]){ $startstr = dateformat($start[0], "F jS Y"); // Start Date $endstr = dateformat($end[0], "F jS Y"); // End Date if(substr($start[1],-2) != "01"){$starttime = " ".timeformat($start[1],0);} // If valid start time, add to string if(substr($end[1],-2) != "01"){$endtime = " ".timeformat($end[1],0);} // If valid end time, add to string if( ($starttime) && ($endtime) ){$dash = " - ";} $datedisplay = "$startstr - $endstr $starttime$dash$endtime"; } } $content .= 'Session '.$x.': '.$datedisplay.'
'; if ($agenda->{"topic".$x}) { $content .= $agenda->{"topic".$x}.' @ '; } if ($agenda->{"url".$x}) { $content .= ''.$agenda->{"sponsor".$x}.''; } else { $content .= $agenda->{"sponsor".$x}; } $content .= '

'; } unset($datedisplay, $start, $end); #} } echo $content; } // Otherwise, shoot the error else { echo 'No current schedules found for this program.
'; } //////////////////////////////////////////////////// // [E] Agenda //////////////////////////////////////////////////// $sql_sponsors = db_exec_sql(" SELECT sponsors.company, sponsors.website from sponsors left join rel_sponsor_program on sponsors.id = rel_sponsor_program.sponsor_id where rel_sponsor_program.program_id = $programid and sponsors.show_on_affiliate = 1 order by company","webdb"); $count = mysql_num_rows($sql_sponsors); if($count){ echo "

Sponsored by:

"; while($list = mysql_fetch_object($sql_sponsors)){ echo "

"; if ($list->website){ if (!strstr($list->website, "http://")){$list->website = "http://".$list->website;} echo ''; } echo $list->company; if ($list->website){ echo ''; } echo "

"; } } echo "
"; ?>