X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=blobdiff_plain;f=plugins%2Fcalendar%2Fday.php;h=4f43637b702ba6940f7e15f359b9b956c87cc94f;hp=feb6489b759cbe7cf6cdda80f9a74f2228a90f8f;hb=95dcee50e4d7ffe1d0b686377042ff3b735bc81c;hpb=cf1efdce52fce19388a74b85903cbeb7fd5e31ad;ds=sidebyside diff --git a/plugins/calendar/day.php b/plugins/calendar/day.php index feb6489b..4f43637b 100644 --- a/plugins/calendar/day.php +++ b/plugins/calendar/day.php @@ -11,13 +11,12 @@ * Displays the day page (day view). * * $Id$ - */ -require_once('calendar_data.php'); -require_once('functions.php'); +define('SM_PATH','../../'); -chdir('..'); -define('SM_PATH','../'); +/* Calender plugin required files. */ +require_once(SM_PATH . 'plugins/calendar/calendar_data.php'); +require_once(SM_PATH . 'plugins/calendar/functions.php'); /* SquirrelMail required files. */ require_once(SM_PATH . 'include/validate.php'); @@ -25,9 +24,31 @@ require_once(SM_PATH . 'functions/strings.php'); require_once(SM_PATH . 'functions/date.php'); require_once(SM_PATH . 'config/config.php'); require_once(SM_PATH . 'functions/page_header.php'); -require_once(SM_PATH . 'src/load_prefs.php'); +require_once(SM_PATH . 'include/load_prefs.php'); require_once(SM_PATH . 'functions/html.php'); +/* get globals */ +if (isset($_GET['year'])) { + $year = $_GET['year']; +} +elseif (isset($_POST['year'])) { + $year = $_POST['year']; +} +if (isset($_GET['month'])) { + $month = $_GET['month']; +} +elseif (isset($_POST['month'])) { + $month = $_POST['month']; +} +if (isset($_GET['day'])) { + $day = $_GET['day']; +} +elseif (isset($_POST['day'])) { + $day = $_POST['day']; +} + +/* got 'em */ + //displays head of day calendar view function day_header() { global $color, $month, $day, $year, $prev_year, $prev_month, $prev_day,