Project

General

Profile

« Previous | Next » 

Revision 1326

Added by Dietmar over 14 years ago

Update headerinfos admin/interface

View differences:

timezones.php
1
<?php
2

  
3
// $Id$
4

  
5
/*
6

  
7
 Website Baker Project <http://www.websitebaker.org/>
8
 Copyright (C) 2004-2009, Ryan Djurovich
9

  
10
 Website Baker is free software; you can redistribute it and/or modify
11
 it under the terms of the GNU General Public License as published by
12
 the Free Software Foundation; either version 2 of the License, or
13
 (at your option) any later version.
14

  
15
 Website Baker is distributed in the hope that it will be useful,
16
 but WITHOUT ANY WARRANTY; without even the implied warranty of
17
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18
 GNU General Public License for more details.
19

  
20
 You should have received a copy of the GNU General Public License
21
 along with Website Baker; if not, write to the Free Software
22
 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
23

  
24
*/
25

  
26
/*
27

  
28
Timezone list file
29

  
30
This file is used to generate a list of timezones for the user to select
31

  
32
*/
33

  
34
if(!defined('WB_URL')) {
35
	header('Location: ../index.php');
36
	exit(0);
37
}
38

  
39
// Create array
40
$TIMEZONES = array();
41

  
42
// Add "System Default" to top of list
43
if(isset($TEXT['SYSTEM_DEFAULT'])) {
44
	$TIMEZONES['-20'] = $TEXT['SYSTEM_DEFAULT'];
45
} else {
46
	$TIMEZONES['-20'] = 'System Default';
47
}
48

  
49
$TIMEZONES['-12'] = 'GMT - 12 Hours';
50
$TIMEZONES['-11'] = 'GMT -11 Hours';
51
$TIMEZONES['-10'] = 'GMT -10 Hours';
52
$TIMEZONES['-9'] = 'GMT -9 Hours';
53
$TIMEZONES['-8'] = 'GMT -8 Hours';
54
$TIMEZONES['-7'] = 'GMT -7 Hours';
55
$TIMEZONES['-6'] = 'GMT -6 Hours';
56
$TIMEZONES['-5'] = 'GMT -5 Hours';
57
$TIMEZONES['-4'] = 'GMT -4 Hours';
58
$TIMEZONES['-3.5'] = 'GMT -3.5 Hours';
59
$TIMEZONES['-3'] = 'GMT -3 Hours';
60
$TIMEZONES['-2'] = 'GMT -2 Hours';
61
$TIMEZONES['-1'] = 'GMT -1 Hour';
62
$TIMEZONES['0'] = 'GMT';
63
$TIMEZONES['1'] = 'GMT +1 Hour';
64
$TIMEZONES['2'] = 'GMT +2 Hours';
65
$TIMEZONES['3'] = 'GMT +3 Hours';
66
$TIMEZONES['3.5'] = 'GMT +3.5 Hours';
67
$TIMEZONES['4'] = 'GMT +4 Hours';
68
$TIMEZONES['4.5'] = 'GMT +4.5 Hours';
69
$TIMEZONES['5'] = 'GMT +5 Hours';
70
$TIMEZONES['5.5'] = 'GMT +5.5 Hours';
71
$TIMEZONES['6'] = 'GMT +6 Hours';
72
$TIMEZONES['6.5'] = 'GMT +6.5 Hours';
73
$TIMEZONES['7'] = 'GMT +7 Hours';
74
$TIMEZONES['8'] = 'GMT +8 Hours';
75
$TIMEZONES['9'] = 'GMT +9 Hours';
76
$TIMEZONES['9.5'] = 'GMT +9.5 Hours';
77
$TIMEZONES['10'] = 'GMT +10 Hours';
78
$TIMEZONES['11'] = 'GMT +11 Hours';
79
$TIMEZONES['12'] = 'GMT +12 Hours';
80
$TIMEZONES['13'] = 'GMT +13 Hours';
81

  
1
<?php
2
/**
3
 *
4
 * @category        admin
5
 * @package         interface
6
 * @author          WebsiteBaker Project
7
 * @copyright       2004-2009, Ryan Djurovich
8
 * @copyright       2009-2010, Website Baker Org. e.V.
9
 * @link            http://www.websitebaker2.org/
10
 * @license         http://www.gnu.org/licenses/gpl.html
11
 * @platform        WebsiteBaker 2.8.x
12
 * @requirements    PHP 4.4.9 and higher
13
 * @version         $Id$
14
 * @filesource      $HeadURL$
15
 * @lastmodified    $Date$
16
 *
17
 * Timezone list file
18
 * This file is used to generate a list of timezones for the user to select
19
 *
20
 */
21

  
22
if(!defined('WB_URL')) {
23
	header('Location: ../index.php');
24
	exit(0);
25
}
26

  
27
// Create array
28
$TIMEZONES = array();
29
$actual_timezone = ( DEFAULT_TIMEZONE <> 0 ) ? DEFAULT_TIMEZONE/3600 : 0;
30

  
31
$TIMEZONES['-12'] = 'GMT - 12 Hours';
32
$TIMEZONES['-11'] = 'GMT -11 Hours';
33
$TIMEZONES['-10'] = 'GMT -10 Hours';
34
$TIMEZONES['-9'] = 'GMT -9 Hours';
35
$TIMEZONES['-8'] = 'GMT -8 Hours';
36
$TIMEZONES['-7'] = 'GMT -7 Hours';
37
$TIMEZONES['-6'] = 'GMT -6 Hours';
38
$TIMEZONES['-5'] = 'GMT -5 Hours';
39
$TIMEZONES['-4'] = 'GMT -4 Hours';
40
$TIMEZONES['-3.5'] = 'GMT -3.5 Hours';
41
$TIMEZONES['-3'] = 'GMT -3 Hours';
42
$TIMEZONES['-2'] = 'GMT -2 Hours';
43
$TIMEZONES['-1'] = 'GMT -1 Hour';
44
$TIMEZONES['0'] = 'GMT';
45
$TIMEZONES['1'] = 'GMT +1 Hour';
46
$TIMEZONES['2'] = 'GMT +2 Hours';
47
$TIMEZONES['3'] = 'GMT +3 Hours';
48
$TIMEZONES['3.5'] = 'GMT +3.5 Hours';
49
$TIMEZONES['4'] = 'GMT +4 Hours';
50
$TIMEZONES['4.5'] = 'GMT +4.5 Hours';
51
$TIMEZONES['5'] = 'GMT +5 Hours';
52
$TIMEZONES['5.5'] = 'GMT +5.5 Hours';
53
$TIMEZONES['6'] = 'GMT +6 Hours';
54
$TIMEZONES['6.5'] = 'GMT +6.5 Hours';
55
$TIMEZONES['7'] = 'GMT +7 Hours';
56
$TIMEZONES['8'] = 'GMT +8 Hours';
57
$TIMEZONES['9'] = 'GMT +9 Hours';
58
$TIMEZONES['9.5'] = 'GMT +9.5 Hours';
59
$TIMEZONES['10'] = 'GMT +10 Hours';
60
$TIMEZONES['11'] = 'GMT +11 Hours';
61
$TIMEZONES['12'] = 'GMT +12 Hours';
62
$TIMEZONES['13'] = 'GMT +13 Hours';
63

  
64
// Add "System Default" to list (if we need to)
65
if(isset($user_time) && $user_time == true)
66
{
67
	if(isset($TEXT['SYSTEM_DEFAULT']))
68
	{
69
		$TIMEZONES['system_default'] = $TIMEZONES[$actual_timezone].' ('.$TEXT['SYSTEM_DEFAULT'].')';
70
	} else {
71
		$TIMEZONES['system_default'] = $TIMEZONES[$actual_timezone].' (System Default)';
72
	}
73
}
74

  
75
// Reverse array so "System Default" is at the top
76
$TIMEZONES = array_reverse($TIMEZONES, true);
77

  
82 78
?>
83 79

  

Also available in: Unified diff