$month1 = 9; } if (empty($month2)) { $month2 = 12; } if (empty($maintabcolumns)) { $maintabcolumns = 6; } require_once "calendar.php"; $cal = new calendar(); if (!empty($maintabcolumns)) { foreach ($params as $param) { $cal->{$param} = ${$param}; } } $text = $cal->show(); $selectedyear++; if (!empty($month1)) { $month1 = 1; } if (!empty($month2)) { $month2 = 8; } if (!empty($maintabcolumns)) { foreach ($params as $param) { $cal->{$param} = ${$param}; } } $text .= $cal->show(); echo get_text($cal, $text, $startyear); ?>
//create calendar $myCal = new calendar($_GET['date']); # create new calendar object (the month overview thing) $myCal->select($_GET['date']); # selects the selected day (default: today) $myDay = new dayView('','',$_GET['date']); # create the new day representer //mark full calendar days //process limits $myDate = explode("-",$_GET['date']); $start = $myDate[2] . "-" . $myDate[1] . "-1 00:00:00"; $end = $myDate[2] . "-" . $myDate[1] . "-" . date("t",mktime(0,0,1,$myDate[1],1,$myDate[2])) . " 23:59:59"; //mark all the days that have content associated with them $myCal->setLinks($db->getCol("SELECT DISTINCT EXTRACT(DAY FROM intime) AS day FROM programme WHERE intime > '$start' AND intime < '$end'")); //show calendar $smarty->assign('calendar',$myCal->show('inside.php')); //#################################### TODAY'S SHOWS ##################################### //get today's programms ;) //process limits $start = $myDate[2] . "-" . $myDate[1] . "-" . $myDate[0] . " 00:00:00"; $end = $myDate[2] . "-" . $myDate[1] . "-" . $myDate[0] . " 23:59:59"; //run the query $todays_shows = $db->getAll("SELECT series.owner AS series_owner, series.title AS series_title, programme.id AS prog_id, programme.title AS prog_title, EXTRACT(EPOCH FROM programme.intime) AS intime, EXTRACT(EPOCH FROM programme.outtime) AS outtime,