content prep:\n"; if($resCount > 0) { $content_arr = array(); $thmb_arr = array(); foreach($res as $key => $val) { $content_arr[$rCount]['contentNo'] = $val['iContentNo']; $content_arr[$rCount]['dbStart'] = $val['dPostStart']; $content_arr[$rCount]['dbEnd'] = $val['dPostEnd']; $content_arr[$rCount]['postYN'] = $val['bPost']; $content_arr[$rCount]['publishYN'] = $val['bPublish']; $content_arr[$rCount]['contentType'] = $val['enContentType']; $content_arr[$rCount]['templateNo'] = $val['iTemplateNo']; $content_arr[$rCount]['pdfFile'] = $val['strPdfFileName']; $content_arr[$rCount]['thmbFile'] = $val['strThmbFileName']; $content_arr[$rCount]['thmbText'] = $val['strThmbText']; $rCount++; } for($i = 0; $i < count($content_arr); $i++) { foreach($content_arr[$i] as $key_1 => $val_1) { //$dbg .= $key_1." = ".$content_arr[$i][$key_1]."\n"; //$pStart = $content_arr[$i]['dbStart']; //$pEnd = $content_arr[$i]['dbEnd']; //$dbg .= "pStart = ".$pStart."\n"; //$dbg .= "pEnd = ".$pEnd."\n"; if($key_1 == 'dbStart') { if(!is_null($content_arr[$i][$key_1]) || $content_arr[$i][$key_1] != '') { $pStart = strtotime($content_arr[$i][$key_1]); } $dbg .= $key_1." = ".$content_arr[$i][$key_1]."\n"; } if($key_1 == 'dbEnd') { if(!is_null($content_arr[$i][$key_1]) || $content_arr[$i][$key_1] != '') { $pEnd = strtotime($content_arr[$i][$key_1]); } $dbg .= $key_1." = ".$content_arr[$i][$key_1]."\n"; } if($key_1 == 'postYN') { if(!$content_arr[$i]['postYN']) { if(!$content_arr[$i][$key_1]) { $dbg .= "post by date: ".$content_arr[$i]['contentNo']."\n"; if($currDate >= $pStart && $currDate <= $pEnd) { if($content_arr[$i]['contentType'] == 'thmb') { $thmb_arr[$tCount]['thmbFile'] = $content_arr[$i]['thmbFile']; $thmb_arr[$tCount]['thmbText'] = $content_arr[$i]['thmbText']; $thmb_arr[$tCount]['pdfFile'] = $content_arr[$i]['pdfFile']; $tCount++; } //pdfFile takes precedence over thumbs. Update DB if todays's date is in conflict with active thumb(s)? if($content_arr[$i]['contentType'] == 'pdf') { $pdfFile = $content_arr[$i]['pdfFile']; } } } else { $dbg .= "post manually: ".$content_arr[$i]['contentNo']."\n"; if($content_arr[$i]['contentType'] == 'thmb') { $thmb_arr[$tCount]['thmbFile'] = $content_arr[$i]['thmbFile']; $thmb_arr[$tCount]['thmbText'] = $content_arr[$i]['thmbText']; $thmb_arr[$tCount]['pdfFile'] = $content_arr[$i]['pdfFile']; $tCount++; } if($content_arr[$i]['contentType'] == 'pdf') { $pdfFile = $content_arr[$i]['pdfFile']; } } } } } $dbg .= "------------------------\n"; } $dbg .= "tCount = ".$tCount."\n"; $dbg .= "pdfFile = ".$pdfFile."\n"; //echo $dbg.""; //exit; } include '../common/header.php'; ?>
  • Events
  • Events

    0) { $tblWid = '100%'; ?>

    CAMPUS HOLIDAYS

     2017 2018
    January2, 16January1, 15
    February20February19
    March31March30
    April April 
    May29May28
    June June 
    July4July4
    August August 
    September4September3
    October October 
    November10, 23, 24November12, 22, 23
    December25, 26, 29December24, 25, 31
    0) { ?>