aboutsummaryrefslogtreecommitdiffstats
path: root/includes
diff options
context:
space:
mode:
authorChad Little <clittle@users.sourceforge.net>2004-01-28 07:27:23 +0000
committerChad Little <clittle@users.sourceforge.net>2004-01-28 07:27:23 +0000
commitc5e73fa883662edaeef6da6a308f6631b6f0eca5 (patch)
tree42d148f0935a961f8bcc02514c0f04f946dfc5ea /includes
parent603060dd7b43d47ac4637fee17b818cba6dff3c8 (diff)
downloadphpicalendar-c5e73fa883662edaeef6da6a308f6631b6f0eca5.zip
phpicalendar-c5e73fa883662edaeef6da6a308f6631b6f0eca5.tar.gz
phpicalendar-c5e73fa883662edaeef6da6a308f6631b6f0eca5.tar.bz2
Major checkin, modified english to new language style. Preferences now
template driven along with event and todo. Header and footer seem to work as well.
Diffstat (limited to 'includes')
-rw-r--r--includes/event.php7
-rw-r--r--includes/todo.php28
2 files changed, 10 insertions, 25 deletions
diff --git a/includes/event.php b/includes/event.php
index 3caad2f..803403f 100644
--- a/includes/event.php
+++ b/includes/event.php
@@ -65,17 +65,12 @@ $page->replace_tags(array(
'event' => $event,
'event_times' => $event_times,
'description' => $description,
- 'organizer_lang' => $organizer_lang,
'organizer' => $organizer,
- 'attendee_lang' => $attendee_lang,
'attendee' => $attendee,
- 'status_lang' => $status_lang,
'status' => $status,
- 'location_lang' => $location_lang,
'location' => $location,
- 'sheet_href' => $sheet_href,
'cal_title_full' => $cal_title_full,
- 'template' => $template,
+ 'template' => $template
));
diff --git a/includes/todo.php b/includes/todo.php
index d9933d7..e783380 100644
--- a/includes/todo.php
+++ b/includes/todo.php
@@ -17,56 +17,46 @@ $start_date = (isset($vtodo_array['start_date'])) ? localizeDate ($dateFormat_d
$due_date = (isset($vtodo_array['due_date'])) ? localizeDate ($dateFormat_day, strtotime($vtodo_array['due_date'])) : ('');
$priority = (isset($vtodo_array['priority'])) ? $vtodo_array['priority'] : ('');
-$cal_title_full = $calendar_name.' '.$calendar_lang;
+$cal_title_full = $calendar_name.' '.$lang['l_calendar'];
$description = ereg_replace("[[:alpha:]]+://[^<>[:space:]]+[[:alnum:]/]", '<a target="_new" href="\0">\0</a>', $description);
$vtodo_text = ereg_replace("[[:alpha:]]+://[^<>[:space:]]+[[:alnum:]/]",'<a target="_new" href="\0">\0</a>',$vtodo_text);
if ((!isset($status) || $status == "COMPLETED") && isset($completed_date)) {
- $status = "$completed_date_lang $completed_date";
-} else if ($status == "COMPLETED") {
+ $status = $lang['l_completed_date'] . ' ' . $completed_date;
+} elseif ($status == "COMPLETED") {
$status = $completed_lang;
} else {
$status = $unfinished_lang;
}
if ($priority >= 1 && $priority <= 4) {
- $priority = $priority_high_lang;
+ $priority = $lang['l_priority_high'];
} else if ($priority == 5) {
- $priority = $priority_medium_lang;
+ $priority = $lang['l_priority_medium'];
} else if ($priority >= 6 && $priority <= 9) {
- $priority = $priority_low_lang;
+ $priority = $lang['l_priority_low'];
} else {
- $priority = $priority_none_lang;
+ $priority = $lang['l_priority_none'];
}
-$display = '';
-if ($vtodo_text != '') $display .= $vtodo_text.'<br><br>';
-if ($description != '') $display .= $description.'<br>';
-if ($status != '') $display .= $status_lang.': '.$status.'<br>';
-if ($priority != '') $display .= $priority_lang.' '.$priority.'<br>';
-if ($start_date != '') $display .= $created_lang.' '.$start_date.'<br>';
-if ($due_date != '') $display .= $due_lang.' '.$due_date.'<br>';
-
$page = new Page(BASE.'templates/'.$template.'/todo.tpl');
$page->replace_tags(array(
'cal' => $cal_title_full,
'vtodo_text' => $vtodo_text,
'description' => $description,
- 'priority_lang' => $priority_lang,
'priority' => $priority,
- 'created_lang' => $created_lang,
'start_date' => $start_date,
- 'status_lang' => $status_lang,
'status' => $status,
- 'due_lang' => $due_lang,
'due_date' => $due_date,
'cal_title_full' => $cal_title_full,
'template' => $template
));
+$page->replace_langs($lang);
+
$page->output();
?> \ No newline at end of file

© 2014-2020 Faster IT GmbH | imprint | privacy policy