$cal->tpl['calendar'] = file_get_contents($basePath . 'templates/' . $template . '/calendar.tpl'); $cal->tpl['dayNoEvent'] = file_get_contents($basePath . 'templates/' . $template . '/dayNoEvent.tpl'); $cal->tpl['dayWithEvent'] = file_get_contents($basePath . 'templates/' . $template . '/dayWithEvent.tpl'); $cal->tpl['eachEvent'] = file_get_contents($basePath . 'templates/' . $template . '/eachEvent.tpl'); $cal->tpl['notInMonth'] = file_get_contents($basePath . 'templates/' . $template . '/notInMonth.tpl'); } else { $cal->tpl['calendar'] = file_get_contents($basePath . 'templates/default/calendar.tpl'); $cal->tpl['dayNoEvent'] = file_get_contents($basePath . 'templates/default/dayNoEvent.tpl'); $cal->tpl['dayWithEvent'] = file_get_contents($basePath . 'templates/default/dayWithEvent.tpl'); $cal->tpl['eachEvent'] = file_get_contents($basePath . 'templates/default/eachEvent.tpl'); $cal->tpl['notInMonth'] = file_get_contents($basePath . 'templates/default/notInMonth.tpl'); } if ($cal_dates) { foreach ($cal_dates as $date) { if ($date['status'] != "canceled" && $date['startMonth'] == $month && strlen(trim($date['sortDate'])) > 0) { $cal->addEvent($date['startDay'], $date); } } #echo '<pre>'; #print_r($cal_dates); #echo '</pre>'; } $output = $cal->display(); } /* End of Calendar Output */ /* Beginning of List Output */ if ($display == 'list') { $tpl['wrapper'] = file_get_contents($basePath . 'templates/' . $template . '/wrapper.tpl'); $tpl['eachEvent'] = file_get_contents($basePath . 'templates/' . $template . '/eachEvent.tpl'); $tpl['eachEventAlt'] = file_get_contents($basePath . 'templates/' . $template . '/eachEventAlt.tpl'); if ($cal_dates) {