From 8933f4144fa0fe022d9939ed2e2f31743f6de939 Mon Sep 17 00:00:00 2001 From: Jim Hu Date: Sun, 28 Dec 2008 00:46:49 +0000 Subject: add back link to print view --- index.php | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'index.php') diff --git a/index.php b/index.php index a865512..05edd88 100644 --- a/index.php +++ b/index.php @@ -3,19 +3,18 @@ if (!defined('BASE')) define('BASE', './'); include_once(BASE.'functions/init.inc.php'); if ($phpiCal_config->printview_default == 'yes') { - $printview = $phpiCal_config->default_view; - $phpiCal_config->setProperty('default_view', "print.php"); + $theview ="print.php"; } else { $check = array ('day', 'week', 'month', 'year'); if (in_array($phpiCal_config->default_view, $check)) { - $phpiCal_config->setProperty('default_view', $phpiCal_config->default_view . '.php'); + $theview = $phpiCal_config->default_view . '.php'; } else { die('illegal view'); } } if(isset($_GET['cpath'])){ - $phpiCal_config->default_view .= '?cpath='.$_GET['cpath']; + $theview .= '?cpath='.$_GET['cpath']; } -header("Location: $phpiCal_config->default_view"); +header("Location: $theview"); ?> -- cgit v1.2.3