} $prgchunk = fix_programs($prgchunk, $fromtime, $totime); reset($prgchunk); while (list($pck, $pcv) = each($prgchunk)) { //dbg("program",$pcv); $cp = cellwidth($pcv, $fromtime, $dconf['timewidth']); //dbg("cp" , $cp ); // if a program is shorter than a value we have // set for shorter cell length -> colspan will be 0 if ($dconf['displayshort'] == "no" && $cp['s'] < 1) { // fill the hole... } else { $cellclass = cellclass_category($pcv, $chv['def_cat']); print "<td align=\"left\" valign=\"top\" width=\"" . $cp['w'] . "%\" colspan=\"" . $cp['s'] . "\" class=\"" . $cellclass . "\">\n"; //print hmins($pcv['start_time']) . " - " . hmins($pcv['end_time']) . "<br>\n"; print hmins($pcv['start_time']) . "<br>\n"; print "<b>"; if ($cellclass != "cat_hole") { print "<a href=\"viewprogram.php?channel=" . $pcv['channel_id'] . "&time=" . str2time($pcv['start_time'], 0) . "\" id=\"program_" . $prgcnt . "\" onmouseover=\"popup('program_" . $prgcnt . "',''); return true;\">"; } #if( $cellclass != "cat_hole" ) print "<a id=\"program_" . $prgcnt . "\" onclick=\"popup('program_" . $prgcnt . "',''); return true;\">"; print $pcv['title']; if ($cellclass != "cat_hole") { print "</a>"; } print "</b><br>\n"; if (isset($pcv['subtitle'])) { print $pcv['subtitle'] . "<br>\n"; } // icons on the bottom print "<table>\n";
dbg("programs", $pdb); } $pdb = fix_programs($pdb, $fromtime, $totime); if ($pdb) { print "\n<!-- now showing table -->\n"; print "<table width=\"75%\" border=\"0\" cellpadding=\"4\" cellspacing=\"2\" class=\"nowshowing\">\n"; print "<tr class=\"tableMenuTitle\">\n"; print " <td class=\"tableMenuBody\">Time</td>\n"; print " <td class=\"tableMenuBody\">Program</td>\n"; print "</tr>\n"; $pdb = array_sort($pdb, "start_time"); reset($pdb); while (list($chk, $chv) = each($pdb)) { print "<tr class=\"tableBody\">\n"; print " <td align=\"center\">\n"; print hmins($chv['start_time']) . " - " . hmins($chv['end_time']); print " </td>\n"; $cellclass = cellclass_category($chv, $chann['def_cat']); print "<td class=\"" . $cellclass . "\">"; if ($cellclass != "cat_hole") { print "<a href=\"viewprogram.php?channel=" . $chv['channel_id'] . "&time=" . str2time($chv['start_time'], 0) . "\">"; } print "<b>" . $chv['title'] . "</b>"; if ($cellclass != "cat_hole") { print "</a>"; } print "</td>\n"; print "</tr>\n"; } print "</table>\n"; }