CheckConfig($function, $args) && $this->CheckLogin("read")) { setlocale("LC_TIME",$AR->nls->locales[$nls]); if (!$PHP_SELF) { global $PHP_SELF; } if (!$date) { $date=time(); } if (!$lookahead) { $lookahead=8; } if (!$priority) { $priority=$this->get("/system/calendar/priorities/todo/","system.get.value.phtml"); if ($priority) { $priority=$priority[0]; } else { $priority=0; } } // calculate first weekday of this month $date_arr=getdate($date); $starttime=0; $endtime=mktime(0,0,0,$date_arr["mon"],$date_arr["mday"]+$lookahead,$date_arr["year"])-1; // now populate the month with all entries. function AddTodo($from, $to, $priority, $path, $name, $summary) { global $ARCurrent, $PHP_SELF; $i=@count($ARCurrent->todolist[$from]); $ARCurrent->todolist[$from][$i]["text"]="$name"; $ARCurrent->todolist[$from][$i]["to"]=$to; } unset($ARBeenHere["populate"]); $ARCurrent->date=$date; $this->populate($starttime, $endtime, $priority, "system.add.time.phtml","timefunc=AddTodo&from=$starttime&to=$endtime"); if ((!is_array($ARCurrent->todolist)) || (count($ARCurrent->todolist)==0)) { $ARCurrent->todolist[0][0]["text"]=$ARnls["notodo"]; $ARCurrent->todolist[0][0]["to"]=-1; } ?> >
">< : ">>
todolist); $open=0; $dottedline="\n"; $lastday=0; $days=24*60*60; while (list($from,$items)=@each($ARCurrent->todolist)) { $from_fmt=strftime("%H:%M",$from); while (list($key, $item)=each($items)) { $change=0; $row="\n"; if ($from>($lastday+$days)) { $row.="$dottedline\n"; $from_arr=getdate($from); $lastday=mktime(0,0,0,$from_arr["mon"],$from_arr["mday"],$from_arr["year"]); } $row.=""; $row.="\n"; $row.=$dottedline; echo $row; } } ?>
dir->images."calendar/dots.gif\">dir->images."dot.gif\" height=\"1\" width=\"1\">
".strftime("%A %d %B",$from). "
"; // now display time if ($from<=$item["to"]) { // notime items dont display the time $row.="$from_fmt"; } $row.="dir->images."dot.gif\" width=\"1\" height=\"17\">"; // now display text $row.=""; $row.=$item["text"]; $row.=""; $row.="