[evolvis-commits] r18369: small-fixes pending merges:↵ Thorsten Glaser 2012-04-24 use timezones from system copy of tzdata, not from 1997’s SourceForge↵ Thorsten Glaser 2012-04-24 move html_get_language_popup to newly created www/account/utils.php

mirabilos at evolvis.org mirabilos at evolvis.org
Tue Apr 24 16:34:47 CEST 2012


Author: mirabilos
Date: 2012-04-24 16:34:46 +0200 (Tue, 24 Apr 2012)
New Revision: 18369

Added:
   trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones-sf.php
   trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones.php
   trunk/gforge_base/evolvisforge-5.1/src/www/account/utils.php
Removed:
   trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones.php
Modified:
   trunk/gforge_base/evolvisforge-5.1/src/www/account/index.php
   trunk/gforge_base/evolvisforge-5.1/src/www/account/register.php
   trunk/gforge_base/evolvisforge-5.1/src/www/include/html.php
Log:
small-fixes pending merges:
  Thorsten Glaser 2012-04-24 use timezones from system copy of tzdata, not from 1997’s SourceForge
    Thorsten Glaser 2012-04-24 move html_get_language_popup to newly created www/account/utils.php

Copied: trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones-sf.php (from rev 18367, trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones.php)
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones-sf.php	                        (rev 0)
+++ trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones-sf.php	2012-04-24 14:34:46 UTC (rev 18369)
@@ -0,0 +1,496 @@
+<?php
+/**
+ * FusionForge
+ *
+ * Copyright 1999-2001, VA Linux Systems, Inc.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+$TZs[]='US/Alaska';
+$TZs[]='US/Aleutian';
+$TZs[]='US/Arizona';
+$TZs[]='US/Central';
+$TZs[]='US/Eastern';
+$TZs[]='US/East-Indiana';
+$TZs[]='US/Hawaii';
+$TZs[]='US/Indiana-Starke';
+$TZs[]='US/Michigan';
+$TZs[]='US/Mountain';
+$TZs[]='US/Pacific';
+$TZs[]='US/Samoa';
+$TZs[]='Africa/Abidjan';
+$TZs[]='Africa/Accra';
+$TZs[]='Africa/Addis_Ababa';
+$TZs[]='Africa/Algiers';
+$TZs[]='Africa/Asmera';
+$TZs[]='Africa/Bamako';
+$TZs[]='Africa/Bangui';
+$TZs[]='Africa/Banjul';
+$TZs[]='Africa/Bissau';
+$TZs[]='Africa/Blantyre';
+$TZs[]='Africa/Brazzaville';
+$TZs[]='Africa/Bujumbura';
+$TZs[]='Africa/Cairo';
+$TZs[]='Africa/Casablanca';
+$TZs[]='Africa/Ceuta';
+$TZs[]='Africa/Conakry';
+$TZs[]='Africa/Dakar';
+$TZs[]='Africa/Dar_es_Salaam';
+$TZs[]='Africa/Djibouti';
+$TZs[]='Africa/Douala';
+$TZs[]='Africa/El_Aaiun';
+$TZs[]='Africa/Freetown';
+$TZs[]='Africa/Gaborone';
+$TZs[]='Africa/Harare';
+$TZs[]='Africa/Johannesburg';
+$TZs[]='Africa/Kampala';
+$TZs[]='Africa/Khartoum';
+$TZs[]='Africa/Kigali';
+$TZs[]='Africa/Kinshasa';
+$TZs[]='Africa/Lagos';
+$TZs[]='Africa/Libreville';
+$TZs[]='Africa/Lome';
+$TZs[]='Africa/Luanda';
+$TZs[]='Africa/Lubumbashi';
+$TZs[]='Africa/Lusaka';
+$TZs[]='Africa/Malabo';
+$TZs[]='Africa/Maputo';
+$TZs[]='Africa/Maseru';
+$TZs[]='Africa/Mbabane';
+$TZs[]='Africa/Mogadishu';
+$TZs[]='Africa/Monrovia';
+$TZs[]='Africa/Nairobi';
+$TZs[]='Africa/Ndjamena';
+$TZs[]='Africa/Niamey';
+$TZs[]='Africa/Nouakchott';
+$TZs[]='Africa/Ouagadougou';
+$TZs[]='Africa/Porto-Novo';
+$TZs[]='Africa/Sao_Tome';
+$TZs[]='Africa/Timbuktu';
+$TZs[]='Africa/Tripoli';
+$TZs[]='Africa/Tunis';
+$TZs[]='Africa/Windhoek';
+$TZs[]='America/Adak';
+$TZs[]='America/Anchorage';
+$TZs[]='America/Anguilla';
+$TZs[]='America/Antigua';
+$TZs[]='America/Araguaina';
+$TZs[]='America/Aruba';
+$TZs[]='America/Asuncion';
+$TZs[]='America/Atka';
+$TZs[]='America/Barbados';
+$TZs[]='America/Belem';
+$TZs[]='America/Belize';
+$TZs[]='America/Boa_Vista';
+$TZs[]='America/Bogota';
+$TZs[]='America/Boise';
+$TZs[]='America/Buenos_Aires';
+$TZs[]='America/Cambridge_Bay';
+$TZs[]='America/Cancun';
+$TZs[]='America/Caracas';
+$TZs[]='America/Catamarca';
+$TZs[]='America/Cayenne';
+$TZs[]='America/Cayman';
+$TZs[]='America/Chicago';
+$TZs[]='America/Chihuahua';
+$TZs[]='America/Cordoba';
+$TZs[]='America/Costa_Rica';
+$TZs[]='America/Cuiaba';
+$TZs[]='America/Curacao';
+$TZs[]='America/Dawson';
+$TZs[]='America/Dawson_Creek';
+$TZs[]='America/Denver';
+$TZs[]='America/Detroit';
+$TZs[]='America/Dominica';
+$TZs[]='America/Edmonton';
+$TZs[]='America/El_Salvador';
+$TZs[]='America/Ensenada';
+$TZs[]='America/Fortaleza';
+$TZs[]='America/Fort_Wayne';
+$TZs[]='America/Glace_Bay';
+$TZs[]='America/Godthab';
+$TZs[]='America/Goose_Bay';
+$TZs[]='America/Grand_Turk';
+$TZs[]='America/Grenada';
+$TZs[]='America/Guadeloupe';
+$TZs[]='America/Guatemala';
+$TZs[]='America/Guayaquil';
+$TZs[]='America/Guyana';
+$TZs[]='America/Halifax';
+$TZs[]='America/Havana';
+$TZs[]='America/Hermosillo';
+$TZs[]='America/Indiana/Indianapolis';
+$TZs[]='America/Indiana/Knox';
+$TZs[]='America/Indiana/Marengo';
+$TZs[]='America/Indiana/Vevay';
+$TZs[]='America/Indianapolis';
+$TZs[]='America/Inuvik';
+$TZs[]='America/Iqaluit';
+$TZs[]='America/Jamaica';
+$TZs[]='America/Jujuy';
+$TZs[]='America/Juneau';
+$TZs[]='America/Knox_IN';
+$TZs[]='America/La_Paz';
+$TZs[]='America/Lima';
+$TZs[]='America/Los_Angeles';
+$TZs[]='America/Louisville';
+$TZs[]='America/Maceio';
+$TZs[]='America/Managua';
+$TZs[]='America/Manaus';
+$TZs[]='America/Martinique';
+$TZs[]='America/Mazatlan';
+$TZs[]='America/Mendoza';
+$TZs[]='America/Menominee';
+$TZs[]='America/Mexico_City';
+$TZs[]='America/Miquelon';
+$TZs[]='America/Montevideo';
+$TZs[]='America/Montreal';
+$TZs[]='America/Montserrat';
+$TZs[]='America/Nassau';
+$TZs[]='America/New_York';
+$TZs[]='America/Nipigon';
+$TZs[]='America/Nome';
+$TZs[]='America/Noronha';
+$TZs[]='America/Panama';
+$TZs[]='America/Pangnirtung';
+$TZs[]='America/Paramaribo';
+$TZs[]='America/Phoenix';
+$TZs[]='America/Port-au-Prince';
+$TZs[]='America/Porto_Acre';
+$TZs[]='America/Port_of_Spain';
+$TZs[]='America/Porto_Velho';
+$TZs[]='America/Puerto_Rico';
+$TZs[]='America/Rainy_River';
+$TZs[]='America/Rankin_Inlet';
+$TZs[]='America/Regina';
+$TZs[]='America/Rosario';
+$TZs[]='America/Santiago';
+$TZs[]='America/Santo_Domingo';
+$TZs[]='America/Sao_Paulo';
+$TZs[]='America/Scoresbysund';
+$TZs[]='America/Shiprock';
+$TZs[]='America/St_Johns';
+$TZs[]='America/St_Kitts';
+$TZs[]='America/St_Lucia';
+$TZs[]='America/St_Thomas';
+$TZs[]='America/St_Vincent';
+$TZs[]='America/Swift_Current';
+$TZs[]='America/Tegucigalpa';
+$TZs[]='America/Thule';
+$TZs[]='America/Thunder_Bay';
+$TZs[]='America/Tijuana';
+$TZs[]='America/Tortola';
+$TZs[]='America/Vancouver';
+$TZs[]='America/Virgin';
+$TZs[]='America/Whitehorse';
+$TZs[]='America/Winnipeg';
+$TZs[]='America/Yakutat';
+$TZs[]='America/Yellowknife';
+$TZs[]='Antarctica/Casey';
+$TZs[]='Antarctica/Davis';
+$TZs[]='Antarctica/DumontDUrville';
+$TZs[]='Antarctica/Mawson';
+$TZs[]='Antarctica/McMurdo';
+$TZs[]='Antarctica/Palmer';
+$TZs[]='Antarctica/South_Pole';
+$TZs[]='Antarctica/Syowa';
+$TZs[]='Arctic/Longyearbyen';
+$TZs[]='Asia/Aden';
+$TZs[]='Asia/Almaty';
+$TZs[]='Asia/Amman';
+$TZs[]='Asia/Anadyr';
+$TZs[]='Asia/Aqtau';
+$TZs[]='Asia/Aqtobe';
+$TZs[]='Asia/Ashkhabad';
+$TZs[]='Asia/Baghdad';
+$TZs[]='Asia/Bahrain';
+$TZs[]='Asia/Baku';
+$TZs[]='Asia/Bangkok';
+$TZs[]='Asia/Beirut';
+$TZs[]='Asia/Bishkek';
+$TZs[]='Asia/Brunei';
+$TZs[]='Asia/Calcutta';
+$TZs[]='Asia/Chungking';
+$TZs[]='Asia/Colombo';
+$TZs[]='Asia/Dacca';
+$TZs[]='Asia/Damascus';
+$TZs[]='Asia/Dili';
+$TZs[]='Asia/Dubai';
+$TZs[]='Asia/Dushanbe';
+$TZs[]='Asia/Gaza';
+$TZs[]='Asia/Harbin';
+$TZs[]='Asia/Hong_Kong';
+$TZs[]='Asia/Hovd';
+$TZs[]='Asia/Irkutsk';
+$TZs[]='Asia/Istanbul';
+$TZs[]='Asia/Jakarta';
+$TZs[]='Asia/Jayapura';
+$TZs[]='Asia/Jerusalem';
+$TZs[]='Asia/Kabul';
+$TZs[]='Asia/Kamchatka';
+$TZs[]='Asia/Karachi';
+$TZs[]='Asia/Kashgar';
+$TZs[]='Asia/Katmandu';
+$TZs[]='Asia/Krasnoyarsk';
+$TZs[]='Asia/Kuala_Lumpur';
+$TZs[]='Asia/Kuching';
+$TZs[]='Asia/Kuwait';
+$TZs[]='Asia/Macao';
+$TZs[]='Asia/Magadan';
+$TZs[]='Asia/Manila';
+$TZs[]='Asia/Muscat';
+$TZs[]='Asia/Nicosia';
+$TZs[]='Asia/Novosibirsk';
+$TZs[]='Asia/Omsk';
+$TZs[]='Asia/Phnom_Penh';
+$TZs[]='Asia/Pyongyang';
+$TZs[]='Asia/Qatar';
+$TZs[]='Asia/Rangoon';
+$TZs[]='Asia/Riyadh';
+$TZs[]='Asia/Riyadh87';
+$TZs[]='Asia/Riyadh88';
+$TZs[]='Asia/Riyadh89';
+$TZs[]='Asia/Saigon';
+$TZs[]='Asia/Samarkand';
+$TZs[]='Asia/Seoul';
+$TZs[]='Asia/Shanghai';
+$TZs[]='Asia/Singapore';
+$TZs[]='Asia/Taipei';
+$TZs[]='Asia/Tashkent';
+$TZs[]='Asia/Tbilisi';
+$TZs[]='Asia/Tehran';
+$TZs[]='Asia/Tel_Aviv';
+$TZs[]='Asia/Thimbu';
+$TZs[]='Asia/Tokyo';
+$TZs[]='Asia/Ujung_Pandang';
+$TZs[]='Asia/Ulaanbaatar';
+$TZs[]='Asia/Ulan_Bator';
+$TZs[]='Asia/Urumqi';
+$TZs[]='Asia/Vientiane';
+$TZs[]='Asia/Vladivostok';
+$TZs[]='Asia/Yakutsk';
+$TZs[]='Asia/Yekaterinburg';
+$TZs[]='Asia/Yerevan';
+$TZs[]='Atlantic/Azores';
+$TZs[]='Atlantic/Bermuda';
+$TZs[]='Atlantic/Canary';
+$TZs[]='Atlantic/Cape_Verde';
+$TZs[]='Atlantic/Faeroe';
+$TZs[]='Atlantic/Jan_Mayen';
+$TZs[]='Atlantic/Madeira';
+$TZs[]='Atlantic/Reykjavik';
+$TZs[]='Atlantic/South_Georgia';
+$TZs[]='Atlantic/Stanley';
+$TZs[]='Atlantic/St_Helena';
+$TZs[]='Australia/ACT';
+$TZs[]='Australia/Adelaide';
+$TZs[]='Australia/Brisbane';
+$TZs[]='Australia/Broken_Hill';
+$TZs[]='Australia/Canberra';
+$TZs[]='Australia/Darwin';
+$TZs[]='Australia/Hobart';
+$TZs[]='Australia/LHI';
+$TZs[]='Australia/Lindeman';
+$TZs[]='Australia/Lord_Howe';
+$TZs[]='Australia/Melbourne';
+$TZs[]='Australia/North';
+$TZs[]='Australia/NSW';
+$TZs[]='Australia/Perth';
+$TZs[]='Australia/Queensland';
+$TZs[]='Australia/South';
+$TZs[]='Australia/Sydney';
+$TZs[]='Australia/Tasmania';
+$TZs[]='Australia/Victoria';
+$TZs[]='Australia/West';
+$TZs[]='Australia/Yancowinna';
+$TZs[]='Brazil/Acre';
+$TZs[]='Brazil/DeNoronha';
+$TZs[]='Brazil/East';
+$TZs[]='Brazil/West';
+$TZs[]='Canada/Atlantic';
+$TZs[]='Canada/Central';
+$TZs[]='Canada/Eastern';
+$TZs[]='Canada/East-Saskatchewan';
+$TZs[]='Canada/Mountain';
+$TZs[]='Canada/Newfoundland';
+$TZs[]='Canada/Pacific';
+$TZs[]='Canada/Saskatchewan';
+$TZs[]='Canada/Yukon';
+$TZs[]='CET';
+$TZs[]='Chile/Continental';
+$TZs[]='Chile/EasterIsland';
+$TZs[]='China/Beijing';
+$TZs[]='China/Shanghai';
+$TZs[]='CST6CDT';
+$TZs[]='Cuba';
+$TZs[]='EET';
+$TZs[]='Egypt';
+$TZs[]='Eire';
+$TZs[]='EST';
+$TZs[]='EST5EDT';
+$TZs[]='Europe/Amsterdam';
+$TZs[]='Europe/Andorra';
+$TZs[]='Europe/Athens';
+$TZs[]='Europe/Belfast';
+$TZs[]='Europe/Belgrade';
+$TZs[]='Europe/Berlin';
+$TZs[]='Europe/Bratislava';
+$TZs[]='Europe/Brussels';
+$TZs[]='Europe/Bucharest';
+$TZs[]='Europe/Budapest';
+$TZs[]='Europe/Chisinau';
+$TZs[]='Europe/Copenhagen';
+$TZs[]='Europe/Dublin';
+$TZs[]='Europe/Gibraltar';
+$TZs[]='Europe/Helsinki';
+$TZs[]='Europe/Istanbul';
+$TZs[]='Europe/Kaliningrad';
+$TZs[]='Europe/Kiev';
+$TZs[]='Europe/Lisbon';
+$TZs[]='Europe/Ljubljana';
+$TZs[]='Europe/London';
+$TZs[]='Europe/Luxembourg';
+$TZs[]='Europe/Madrid';
+$TZs[]='Europe/Malta';
+$TZs[]='Europe/Minsk';
+$TZs[]='Europe/Monaco';
+$TZs[]='Europe/Moscow';
+$TZs[]='Europe/Oslo';
+$TZs[]='Europe/Paris';
+$TZs[]='Europe/Prague';
+$TZs[]='Europe/Riga';
+$TZs[]='Europe/Rome';
+$TZs[]='Europe/Samara';
+$TZs[]='Europe/San_Marino';
+$TZs[]='Europe/Sarajevo';
+$TZs[]='Europe/Simferopol';
+$TZs[]='Europe/Skopje';
+$TZs[]='Europe/Sofia';
+$TZs[]='Europe/Stockholm';
+$TZs[]='Europe/Tallinn';
+$TZs[]='Europe/Tirane';
+$TZs[]='Europe/Tiraspol';
+$TZs[]='Europe/Uzhgorod';
+$TZs[]='Europe/Vaduz';
+$TZs[]='Europe/Vatican';
+$TZs[]='Europe/Vienna';
+$TZs[]='Europe/Vilnius';
+$TZs[]='Europe/Warsaw';
+$TZs[]='Europe/Zagreb';
+$TZs[]='Europe/Zaporozhye';
+$TZs[]='Europe/Zurich';
+$TZs[]='Factory';
+$TZs[]='GB';
+$TZs[]='GB-Eire';
+$TZs[]='GMT';
+$TZs[]='GMT0';
+$TZs[]='GMT-0';
+$TZs[]='GMT+0';
+$TZs[]='Greenwich';
+$TZs[]='Hongkong';
+$TZs[]='HST';
+$TZs[]='Iceland';
+$TZs[]='Indian/Antananarivo';
+$TZs[]='Indian/Chagos';
+$TZs[]='Indian/Christmas';
+$TZs[]='Indian/Cocos';
+$TZs[]='Indian/Comoro';
+$TZs[]='Indian/Kerguelen';
+$TZs[]='Indian/Mahe';
+$TZs[]='Indian/Maldives';
+$TZs[]='Indian/Mauritius';
+$TZs[]='Indian/Mayotte';
+$TZs[]='Indian/Reunion';
+$TZs[]='Iran';
+$TZs[]='Israel';
+$TZs[]='Jamaica';
+$TZs[]='Japan';
+$TZs[]='Kwajalein';
+$TZs[]='Libya';
+$TZs[]='MET';
+$TZs[]='Mexico/BajaNorte';
+$TZs[]='Mexico/BajaSur';
+$TZs[]='Mexico/General';
+$TZs[]='Mideast/Riyadh87';
+$TZs[]='Mideast/Riyadh88';
+$TZs[]='Mideast/Riyadh89';
+$TZs[]='MST';
+$TZs[]='MST7MDT';
+$TZs[]='Navajo';
+$TZs[]='NZ';
+$TZs[]='NZ-CHAT';
+$TZs[]='Pacific/Apia';
+$TZs[]='Pacific/Auckland';
+$TZs[]='Pacific/Chatham';
+$TZs[]='Pacific/Easter';
+$TZs[]='Pacific/Efate';
+$TZs[]='Pacific/Enderbury';
+$TZs[]='Pacific/Fakaofo';
+$TZs[]='Pacific/Fiji';
+$TZs[]='Pacific/Funafuti';
+$TZs[]='Pacific/Galapagos';
+$TZs[]='Pacific/Gambier';
+$TZs[]='Pacific/Guadalcanal';
+$TZs[]='Pacific/Guam';
+$TZs[]='Pacific/Honolulu';
+$TZs[]='Pacific/Johnston';
+$TZs[]='Pacific/Kiritimati';
+$TZs[]='Pacific/Kosrae';
+$TZs[]='Pacific/Kwajalein';
+$TZs[]='Pacific/Majuro';
+$TZs[]='Pacific/Marquesas';
+$TZs[]='Pacific/Midway';
+$TZs[]='Pacific/Nauru';
+$TZs[]='Pacific/Niue';
+$TZs[]='Pacific/Norfolk';
+$TZs[]='Pacific/Noumea';
+$TZs[]='Pacific/Pago_Pago';
+$TZs[]='Pacific/Palau';
+$TZs[]='Pacific/Pitcairn';
+$TZs[]='Pacific/Ponape';
+$TZs[]='Pacific/Port_Moresby';
+$TZs[]='Pacific/Rarotonga';
+$TZs[]='Pacific/Saipan';
+$TZs[]='Pacific/Samoa';
+$TZs[]='Pacific/Tahiti';
+$TZs[]='Pacific/Tarawa';
+$TZs[]='Pacific/Tongatapu';
+$TZs[]='Pacific/Truk';
+$TZs[]='Pacific/Wake';
+$TZs[]='Pacific/Wallis';
+$TZs[]='Pacific/Yap';
+$TZs[]='Poland';
+$TZs[]='Portugal';
+$TZs[]='PRC';
+$TZs[]='PST8PDT';
+$TZs[]='ROC';
+$TZs[]='ROK';
+$TZs[]='Singapore';
+$TZs[]='Turkey';
+$TZs[]='UCT';
+$TZs[]='Universal';
+$TZs[]='UTC';
+$TZs[]='WET';
+$TZs[]='W-SU';
+$TZs[]='Zulu';
+
+// Local Variables:
+// mode: php
+// c-file-style: "bsd"
+// End:
+
+?>

Added: trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones.php	                        (rev 0)
+++ trunk/gforge_base/evolvisforge-5.1/src/common/include/timezones.php	2012-04-24 14:34:46 UTC (rev 18369)
@@ -0,0 +1,65 @@
+<?php
+/*-
+ * Import system timezones into PHP, for FusionForge
+ *
+ * Copyright © 2012
+ *	Thorsten “mirabilos” Glaser <t.glaser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+unset($TZs);
+if (file_exists("/usr/share/zoneinfo/UTC")) {
+	/* avoid making $TZs a reference, which ls() returns */
+	foreach (ls("/usr/share/zoneinfo") as $j) {
+		if (!in_array($j, array(
+			'Factory',
+			'iso3166.tab',
+			'localtime',
+			'posix',
+			'posixrules',
+			'right',
+			'zone.tab',
+		    ))) {
+			/* not masked or non-timezone */
+			$TZs[] = $j;
+		}
+	}
+	$j = true;
+	while ($j) {
+		sort($TZs);
+		$i = count($TZs);
+		$j = false;
+		while ($i-- > 0) {
+			if (is_dir("/usr/share/zoneinfo/" . $TZs[$i])) {
+				foreach (ls("/usr/share/zoneinfo/" . $TZs[$i])
+				    as $j) {
+					$TZs[] = $TZs[$i] . "/" . $j;
+				}
+				unset($TZs[$i]);
+				$j = true;
+				break;
+			}
+		}
+	}
+	sort($TZs);
+}
+
+if (!isset($TZs) || !$TZs) {
+	/* fall back to SourceForge compiled-in list */
+	include dirname(__FILE__).'/timezones-sf.php';
+}

Modified: trunk/gforge_base/evolvisforge-5.1/src/www/account/index.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/src/www/account/index.php	2012-04-24 09:41:51 UTC (rev 18368)
+++ trunk/gforge_base/evolvisforge-5.1/src/www/account/index.php	2012-04-24 14:34:46 UTC (rev 18369)
@@ -26,6 +26,7 @@
 require_once $gfcommon.'include/pre.php';
 require_once $gfcommon.'include/timezones.php';
 require_once $gfcommon.'include/datepick.php';
+require_once $gfwww.'account/utils.php';
 
 $feedback = htmlspecialchars(getStringFromRequest('feedback'));
 $error_msg = htmlspecialchars(getStringFromRequest('error_msg'));

Modified: trunk/gforge_base/evolvisforge-5.1/src/www/account/register.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/src/www/account/register.php	2012-04-24 09:41:51 UTC (rev 18368)
+++ trunk/gforge_base/evolvisforge-5.1/src/www/account/register.php	2012-04-24 14:34:46 UTC (rev 18369)
@@ -26,6 +26,7 @@
 require_once $gfcommon.'include/pre.php';
 require_once $gfcommon.'include/account.php';
 require_once $gfcommon.'include/timezones.php';
+require_once $gfwww.'account/utils.php';
 
 if (forge_get_config ('user_registration_restricted')) {
 	session_require_global_perm ('forge_admin');

Added: trunk/gforge_base/evolvisforge-5.1/src/www/account/utils.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/src/www/account/utils.php	                        (rev 0)
+++ trunk/gforge_base/evolvisforge-5.1/src/www/account/utils.php	2012-04-24 14:34:46 UTC (rev 18369)
@@ -0,0 +1,39 @@
+<?php
+/*-
+ * www/account utils for FusionForge
+ *
+ * Copyright 1999-2001 (c) VA Linux Systems
+ * Copyright 2010 (c) FusionForge Team
+ * Copyright (C) 2010 Alain Peyrat - Alcatel-Lucent
+ * Copyright © 2011, 2012
+ *	Thorsten “mirabilos” Glaser <t.glaser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+/**
+ * html_get_language_popup() - Pop up box of supported languages.
+ *
+ * @param		string	The title of the popup box.
+ * @param		string	Which element of the box is to be selected.
+ * @return	string	The html select box.
+ */
+function html_get_language_popup ($title='language_id',$selected='xzxz') {
+	$res = db_query_params ('SELECT * FROM supported_languages ORDER BY name ASC',
+			array ());	
+	return html_build_select_box ($res,$title,$selected,false);
+}

Modified: trunk/gforge_base/evolvisforge-5.1/src/www/include/html.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/src/www/include/html.php	2012-04-24 09:41:51 UTC (rev 18368)
+++ trunk/gforge_base/evolvisforge-5.1/src/www/include/html.php	2012-04-24 14:34:46 UTC (rev 18369)
@@ -168,19 +168,6 @@
 }
 
 /**
- * html_get_language_popup() - Pop up box of supported languages.
- *
- * @param		string	The title of the popup box.
- * @param		string	Which element of the box is to be selected.
- * @return	string	The html select box.
- */
-function html_get_language_popup ($title='language_id',$selected='xzxz') {
-	$res = db_query_params ('SELECT * FROM supported_languages ORDER BY name ASC',
-			array ());	
-	return html_build_select_box ($res,$title,$selected,false);
-}
-
-/**
  * html_get_theme_popup() - Pop up box of supported themes.
  *
  * @param		string	The title of the popup box.



More information about the evolvis-commits mailing list