Source for file timezones.php
Documentation is available at timezones.php
* SquirrelMail Time zone functions
* Function load time zone array selected in SquirrelMail
* Time zone array must consist of key name that matches key in
* standard time zone array and 'NAME' and 'TZ' subkeys. 'NAME'
* key should store translatable key name. 'TZ' key should store
* time zone name that will be used in TZ environment variable.
* Both subkeys are optional. If they are not present, time zone
* @copyright © 1999-2006 The SquirrelMail Project Team
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
* @version $Id: timezones.php,v 1.5 2006/07/15 12:01:08 tokul Exp $
* Returns time zone array set in SquirrelMail configuration
* @return array time zone array
// variable is not set or empty
if (! isset
($time_zone_type) ||
empty($time_zone_type)) {
// make sure that it is integer
$time_zone_type = (int)
$time_zone_type;
* TODO: which one is better (global + include_once) or (include)
switch ($time_zone_type) {
include(SM_PATH .
'config/timezones.php');
// standard (default) time zone set
include(SM_PATH .
'include/timezones/standard.php');
* @param string time zone string
* @return string time zone name used for TZ env
* (false, if timezone does not exists and server's TZ should be used)
// get real time zone from link
if (isset
($aTZs[$sTZ]['LINK'])) {
$sTZ =
$aTZs[$sTZ]['LINK'];
if (isset
($aTZs[$sTZ])) {
if (isset
($aTZs[$sTZ]['TZ'])) {
return $aTZs[$sTZ]['TZ'];
// array does not have TZ entry. bad thing
Documentation generated on Sat, 07 Oct 2006 16:13:58 +0300 by phpDocumentor 1.3.0RC6