$first_time->subtractSeconds(1); $last_time = new CDate($date); $last_time->setDay($date->getDaysInMonth()); $last_time->setTime(23, 59, 59); $links = array(); // assemble the links for the tasks require_once dPgetConfig('root_dir') . "/modules/calendar/links_tasks.php"; getTaskLinks($first_time, $last_time, $links, 20, $company_id); // assemble the links for the events require_once dPgetConfig('root_dir') . "/modules/calendar/links_events.php"; getEventLinks($first_time, $last_time, $links, 20); // create the main calendar $cal->setLinkFunctions('clickDay', 'clickWeek'); $cal->setEvents($links); } else { $cal->setHolidayHandler('setHolidayInfo'); } echo $cal->show(); //echo '<pre>';print_r($cal);echo '</pre>'; // create the mini previous and next month calendars under $minical = new CMonthCalendar($cal->prev_month); $minical->setStyles('minititle', 'minical'); $minical->showArrows = false; $minical->showWeek = false; $minical->clickMonth = true; $minical->setLinkFunctions('clickDay'); ?> <table cellspacing="2" cellpadding="0" border="0" width="100%"> <tr> <td valign="top" align="center" width="200" class="minicalb"><?php echo $minical->show();