From 9f5b31c395b1af54175fb0d4afe3a1d9e931045a Mon Sep 17 00:00:00 2001 From: Chad Little Date: Wed, 18 Aug 2004 00:14:48 +0000 Subject: Updated for speeds. --- admin.php | 8 +++++--- month.php | 8 ++++++-- preferences.php | 7 +++++-- print.php | 7 +++++-- rss/index.php | 7 +++++-- week.php | 7 +++++-- year.php | 7 +++++-- 7 files changed, 36 insertions(+), 15 deletions(-) diff --git a/admin.php b/admin.php index c637ec4..4d2dfc3 100644 --- a/admin.php +++ b/admin.php @@ -43,10 +43,12 @@ $calendar_name = $lang['l_admin_header']; $page = new Page(BASE.'templates/'.$template.'/admin.tpl'); -$page->replace_tags(array( +$page->replace_files(array( 'header' => BASE.'templates/'.$template.'/header.tpl', - 'footer' => BASE.'templates/'.$template.'/footer.tpl', - 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl', + 'footer' => BASE.'templates/'.$template.'/footer.tpl' + )); + +$page->replace_tags(array( 'event_js' => BASE.'functions/event.js', 'charset' => $charset, 'default_path' => '', diff --git a/month.php b/month.php index 564a707..7e186aa 100644 --- a/month.php +++ b/month.php @@ -49,10 +49,14 @@ $list_jumps = list_jumps(); $list_calcolors = list_calcolors(); $page = new Page(BASE.'templates/'.$template.'/month.tpl'); -$page->replace_tags(array( + +$page->replace_files(array( 'header' => BASE.'templates/'.$template.'/header.tpl', 'footer' => BASE.'templates/'.$template.'/footer.tpl', - 'calendar_nav' => BASE.'templates/'.$template.'/calendar_nav.tpl', + 'sidebar' => BASE.'templates/'.$template.'/calendar_nav.tpl' + )); + +$page->replace_tags(array( 'event_js' => BASE.'functions/event.js', 'charset' => $charset, 'template' => $template, diff --git a/preferences.php b/preferences.php index 810c77d..0d8badc 100644 --- a/preferences.php +++ b/preferences.php @@ -133,9 +133,12 @@ $generated = number_format(($php_ended-$php_started),3); $page = new Page(BASE.'templates/'.$template.'/preferences.tpl'); -$page->replace_tags(array( +$page->replace_files(array( 'header' => BASE.'templates/'.$template.'/header.tpl', - 'footer' => BASE.'templates/'.$template.'/footer.tpl', + 'footer' => BASE.'templates/'.$template.'/footer.tpl' + )); + +$page->replace_tags(array( 'charset' => $charset, 'template' => $template, 'default_path' => '', diff --git a/print.php b/print.php index 59144b5..14600dd 100644 --- a/print.php +++ b/print.php @@ -38,10 +38,13 @@ if ($printview == 'day') { $page = new Page(BASE.'templates/'.$template.'/print.tpl'); -$page->replace_tags(array( +$page->replace_files(array( 'header' => BASE.'templates/'.$template.'/header.tpl', 'footer' => BASE.'templates/'.$template.'/footer.tpl', - 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl', + 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl' + )); + +$page->replace_tags(array( 'event_js' => BASE.'functions/event.js', 'charset' => $charset, 'default_path' => '', diff --git a/rss/index.php b/rss/index.php index e16bb1b..b8649a1 100644 --- a/rss/index.php +++ b/rss/index.php @@ -27,9 +27,12 @@ foreach ($filelist as $file) { $page = new Page(BASE.'templates/'.$template.'/rss_index.tpl'); -$page->replace_tags(array( +$page->replace_files(array( 'header' => BASE.'templates/'.$template.'/header.tpl', - 'footer' => BASE.'templates/'.$template.'/footer.tpl', + 'footer' => BASE.'templates/'.$template.'/footer.tpl' + )); + +$page->replace_tags(array( 'event_js' => BASE.'functions/event.js', 'default_path' => $default_path.'/', 'template' => $template, diff --git a/week.php b/week.php index 15ceb89..488bb9d 100644 --- a/week.php +++ b/week.php @@ -45,10 +45,13 @@ $logout_querys = logout_querys(); $page = new Page(BASE.'templates/'.$template.'/week.tpl'); -$page->replace_tags(array( +$page->replace_files(array( 'header' => BASE.'templates/'.$template.'/header.tpl', 'footer' => BASE.'templates/'.$template.'/footer.tpl', - 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl', + 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl' + )); + +$page->replace_tags(array( 'event_js' => BASE.'functions/event.js', 'charset' => $charset, 'default_path' => '', diff --git a/year.php b/year.php index a77fa9e..e6bcf70 100644 --- a/year.php +++ b/year.php @@ -17,9 +17,12 @@ $prev_year = date ("Ymd", $prev_year); $page = new Page(BASE.'templates/'.$template.'/year.tpl'); -$page->replace_tags(array( +$page->replace_files(array( 'header' => BASE.'templates/'.$template.'/header.tpl', - 'footer' => BASE.'templates/'.$template.'/footer.tpl', + 'footer' => BASE.'templates/'.$template.'/footer.tpl' + )); + +$page->replace_tags(array( 'template' => $template, 'charset' => $charset, 'default_path' => '', -- cgit v1.2.3