aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJim Hu <jimhu@users.sourceforge.net>2008-12-27 23:49:39 +0000
committerJim Hu <jimhu@users.sourceforge.net>2008-12-27 23:49:39 +0000
commita8a822e8fe1916540ea4bce97c4861bb452ab21f (patch)
treed6370f5ef2b5daf99c2bc0a478b2e7bab46d2713
parentfb1fa4e8eeb2accaf71675dbf9810ec5af47bc79 (diff)
downloadphpicalendar-a8a822e8fe1916540ea4bce97c4861bb452ab21f.zip
phpicalendar-a8a822e8fe1916540ea4bce97c4861bb452ab21f.tar.gz
phpicalendar-a8a822e8fe1916540ea4bce97c4861bb452ab21f.tar.bz2
add timezones to prefs
-rw-r--r--config.inc.php2
-rw-r--r--default_config.php2
-rw-r--r--functions/timezones.php1
-rw-r--r--preferences.php52
4 files changed, 55 insertions, 2 deletions
diff --git a/config.inc.php b/config.inc.php
index 72ac12b..943886f 100644
--- a/config.inc.php
+++ b/config.inc.php
@@ -30,7 +30,7 @@ As noted, phpicalendar should work without adjusting the default settings. Chan
/* ** Timezones **
If timezone is not set, all events show in the local time of the source calendar. This isn't a problem if all your calendars are in the same timezone. If you set a timezone for the server, events in other timezones are shown when they occur at the server's time.
*/
-# 'timezone' => 'US/Central',
+ 'timezone' => 'US/Central',
# 'second_offset' => $secs,
/* ** Appearance **
diff --git a/default_config.php b/default_config.php
index 90c54e0..ef7acd4 100644
--- a/default_config.php
+++ b/default_config.php
@@ -2,7 +2,7 @@
class Configs{
private static $instance;
private function __construct(){
- $this->phpicalendar_version = '2.3rc1.3';
+ $this->phpicalendar_version = '2.3rc1.4';
// Configuration file for PHP iCalendar 2.25rc1
//
// To set values, change the text between the single quotes
diff --git a/functions/timezones.php b/functions/timezones.php
index ae140f0..81a7ee8 100644
--- a/functions/timezones.php
+++ b/functions/timezones.php
@@ -381,6 +381,7 @@ $tz_array['Europe/Zagreb'] = array('+0100', '+0200');
$tz_array['Europe/Zaporozhye'] = array('+0200', '+0300');
$tz_array['Europe/Zurich'] = array('+0100', '+0200');
$tz_array['GB'] = array('+0000', '+0100');
+$tz_array['GMT'] = array('+0000', '+0000');
$tz_array['GB-Eire'] = array('+0000', '+0100');
$tz_array['HST'] = array('-1000', '-1000');
$tz_array['Hongkong'] = array('+0800', '+0800');
diff --git a/preferences.php b/preferences.php
index 1067106..9bcda9c 100644
--- a/preferences.php
+++ b/preferences.php
@@ -144,6 +144,58 @@ foreach ($daysofweek_lang as $daysofweek) {
$i++;
}
+$timezone_subset = array(
+ '',
+ 'GMT',
+ 'US/Hawaii',
+ 'US/Pacific',
+ 'US/Mountain',
+ 'US/Central',
+ 'US/Eastern',
+ 'Canada/Newfoundland',
+ 'CET',
+ 'EET',
+ 'Etc/GMT-1',
+ 'Etc/GMT-2',
+ 'Etc/GMT-3',
+ 'Etc/GMT-4',
+ 'Etc/GMT-5',
+ 'Etc/GMT-6',
+ 'Etc/GMT-7',
+ 'Etc/GMT-8',
+ 'Etc/GMT-9',
+ 'Etc/GMT-10',
+ 'Etc/GMT-11',
+ 'Etc/GMT-12',
+ 'Etc/GMT-13',
+ 'Etc/GMT-14',
+ 'Etc/GMT+1',
+ 'Etc/GMT+2',
+ 'Etc/GMT+3',
+ 'Etc/GMT+4',
+ 'Etc/GMT+5',
+ 'Etc/GMT+6',
+ 'Etc/GMT+7',
+ 'Etc/GMT+8',
+ 'Etc/GMT+9',
+ 'Etc/GMT+10',
+ 'Etc/GMT+11',
+ 'Etc/GMT+12',
+ 'MET',
+ 'Mexico/General',
+ 'NZ',
+ 'WET'
+);
+$timezone_select = '';
+foreach ($timezone_subset as $i => $timezone) {
+ if ($timezone_subset[$i] == $cookie_timezone) {
+ $timezone_select .= "<option value='$timezone' selected='selected'>$timezone</option>\n";
+ } else {
+ $timezone_select .= "<option value='$timezone.'>$timezone</option>\n";
+ }
+}
+
+
$dir_handle = @opendir(BASE.'templates/');
$style_select = '';
while ($file = readdir($dir_handle)) {

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