New extension added, more EL-rewrites, naming-convention applied:
authorRoland Häder <roland@mxchange.org>
Mon, 28 Jun 2010 05:14:11 +0000 (05:14 +0000)
committerRoland Häder <roland@mxchange.org>
Mon, 28 Jun 2010 05:14:11 +0000 (05:14 +0000)
- New extension 'ext-timezone' added to more easilier change the timezone
  this installation runs with. It is essential to install this extension and
  keep it active.
- Even more rewrites to make use of EL
- theme_ver is outdated, we use theme_version (no short-cutted texts)
- TODOs.txt updated

25 files changed:
.gitattributes
DOCS/TODOs.txt
DOCS/prop-set.sh
inc/config-global.php
inc/extensions-functions.php
inc/extensions/ext-sql_patches.php
inc/extensions/ext-theme.php
inc/extensions/ext-timezone.php [new file with mode: 0644]
inc/language/timezone_de.php [new file with mode: 0644]
inc/libs/theme_functions.php
inc/libs/timezone_functions.php [new file with mode: 0644]
inc/modules/admin/what-config_proxy.php
inc/modules/admin/what-config_timezone.php [new file with mode: 0644]
inc/modules/admin/what-theme_check.php
inc/modules/admin/what-theme_edit.php
inc/modules/admin/what-theme_import.php
inc/modules/member/what-themes.php
templates/de/html/admin/admin_config_proxy.tpl
templates/de/html/admin/admin_config_timezone.tpl [new file with mode: 0644]
templates/de/html/admin/admin_list_theme.tpl
templates/de/html/admin/admin_list_theme_row.tpl
templates/de/html/admin/admin_theme_edit_row.tpl
templates/de/html/admin/admin_theme_import_row.tpl
templates/de/html/ext/ext_sql_patches.tpl
templates/de/html/ext/ext_timezone.tpl [new file with mode: 0644]

index f8c01da..72a12c7 100644 (file)
@@ -260,6 +260,7 @@ inc/language/support_de.php -text
 inc/language/surfbar_de.php -text
 inc/language/task_de.php -text
 inc/language/theme_de.php -text
+inc/language/timezone_de.php -text
 inc/language/top10_de.php -text
 inc/language/transfer_de.php -text
 inc/language/usage_de.php -text
@@ -304,6 +305,7 @@ inc/libs/sponsor_functions.php -text
 inc/libs/surfbar_functions.php -text
 inc/libs/task_functions.php -text
 inc/libs/theme_functions.php -text
+inc/libs/timezone_functions.php -text
 inc/libs/transfer_functions.php -text
 inc/libs/uberwach_functions.php -text
 inc/libs/user_functions.php -text
@@ -413,6 +415,7 @@ inc/modules/admin/what-config_session.php -text
 inc/modules/admin/what-config_sponsor.php -text
 inc/modules/admin/what-config_stats.php -text
 inc/modules/admin/what-config_surfbar.php -text
+inc/modules/admin/what-config_timezone.php -text
 inc/modules/admin/what-config_title.php -text
 inc/modules/admin/what-config_top10.php -text
 inc/modules/admin/what-config_transfer.php -text
@@ -983,6 +986,7 @@ templates/de/html/admin/admin_config_sponsor.tpl -text
 templates/de/html/admin/admin_config_stats.tpl -text
 templates/de/html/admin/admin_config_sub_points.tpl -text
 templates/de/html/admin/admin_config_surfbar.tpl -text
+templates/de/html/admin/admin_config_timezone.tpl -text
 templates/de/html/admin/admin_config_title.tpl -text
 templates/de/html/admin/admin_config_top10.tpl -text
 templates/de/html/admin/admin_config_transfer.tpl -text
@@ -1368,6 +1372,7 @@ templates/de/html/ext/ext_support.tpl -text
 templates/de/html/ext/ext_surfbar.tpl -text
 templates/de/html/ext/ext_task.tpl -text
 templates/de/html/ext/ext_theme.tpl -text
+templates/de/html/ext/ext_timezone.tpl -text
 templates/de/html/ext/ext_top10.tpl -text
 templates/de/html/ext/ext_transfer.tpl -text
 templates/de/html/ext/ext_uberwach.tpl -text
index 9fda182..237437f 100644 (file)
 ./inc/extensions/ext-order.php:344:            // @TODO This should be moved out to inc/reset/
 ./inc/extensions/ext-rallye.php:331:           // @TODO Move this code into rallye_functions.php
 ./inc/extensions/ext-rallye.php:94:            // @TODO Fix config_rallye_prices to list_rallye_prices
-./inc/extensions/ext-sql_patches.php:755:                      // @TODO Rewrite this to a filter
+./inc/extensions/ext-sql_patches.php:763:                      // @TODO Rewrite this to a filter
 ./inc/extensions/ext-yoomedia.php:123:         // @TODO Can this be moved into a database table?
 ./inc/extensions/ext-yoomedia.php:56:// @TODO Only deprecated when 'ext-network' is ready! setExtensionDeprecated('Y');
 ./inc/extensions-functions.php:143:    // @TODO Do we still need this? setExtensionUpdateNotes('');
-./inc/extensions-functions.php:423:// @TODO Change from ext_id to ext_name (not just even the variable! ;-) )
-./inc/extensions-functions.php:539:            // @TODO Extension is loaded, what next?
+./inc/extensions-functions.php:422:// @TODO Change from ext_id to ext_name (not just even the variable! ;-) )
+./inc/extensions-functions.php:538:            // @TODO Extension is loaded, what next?
 ./inc/functions.php:1078:// @TODO $simple/$constants are deprecated
 ./inc/functions.php:1105:      // @TODO Do only use $content and deprecate $GLOBALS and $DATA in templates
 ./inc/functions.php:2382:      // @TODO This can be easily moved out after the merge from EL branch to this is complete
 ./templates/de/html/surfbar/surfbar_frame_top.tpl:32:// @TODO Try to rewrite this JavaScript to js.php?js=surfbar_frame_top (wouldn't be easy)
 ### ### DEPRECATION FOLLOWS: ### ###
 ./inc/modules/admin/admin-inc.php:432:// @DEPRECATED
+./inc/modules/admin/what-theme_check.php:2:// @DEPRECATED
+./templates/de/html/admin/admin_list_theme_row.tpl:1:<!-- @DEPRECATED //-->
+./templates/de/html/admin/admin_list_theme.tpl:1:<!-- @DEPRECATED //-->
 ### ### template-warnings.log follows: ### ###
 Warning: Not parsing JavaScript templates/de/html/js/js_order_send.tpl.
 Warning: Not parsing JavaScript templates/de/html/js/js_cookies_disabled.tpl.
index c57b419..cfb62ec 100755 (executable)
@@ -3,4 +3,5 @@
 find -type f -name "*.php" -exec svn propset svn:keywords "Author Id Revision HeadURL Date Tag" {} \;
 find -type f -name "*-" -exec svn propset svn:keywords "Author Id Revision HeadURL Date Tag" {} \;
 find -type f -name "*_" -exec svn propset svn:keywords "Author Id Revision HeadURL Date Tag" {} \;
+find -type f -name "_*.php" -exec svn propset svn:keywords "Author Id Revision HeadURL Date Tag" {} \;
 find inc/phpmailer/ -type f -name "*.php" -exec svn propdel svn:keywords {} \;
index 5c71105..2861f71 100644 (file)
@@ -46,11 +46,6 @@ if (!defined('__SECURITY')) {
  *      PLEASE DO NOT EDIT THE COMMENTS! install.php NEEDS THEM!        *
  ************************************************************************/
 
-if (function_exists('date_default_timezone_set')) {
-       // CFG: TIME-ZONE
-       @date_default_timezone_set('Europe/Berlin');
-} // END - if
-
 // CFG: ERROR_REPORTING
 error_reporting(E_ALL | E_STRICT);
 
index a05bb7b..06a2c16 100644 (file)
@@ -377,11 +377,10 @@ function registerExtension ($ext_name, $task_id, $dry_run = false, $logout = tru
                                // In normal mode return a true on success
                                $ret = true;
                        } elseif (getExtensionDryRun() === true) {
-                               // In  "dry-run" mode return array with all SQL commands
-                               $ret = getExtensionSqls();
+                               // In  "dry-run" mode do always return a true
+                               $ret = true;
 
                                // Re-init queries and notes
-                               initExtensionSqls(true);
                                initExtensionNotes();
                        } else {
                                // Extension has been removed for updates, so all is fine!
index da81139..4e64404 100644 (file)
@@ -43,10 +43,10 @@ if (!defined('__SECURITY')) {
 } // END - if
 
 // Version number
-setThisExtensionVersion('0.7.0');
+setThisExtensionVersion('0.7.1');
 
 // Version history array (add more with , '0.1.0' and so on)
-setExtensionVersionHistory(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0'));
+setExtensionVersionHistory(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1'));
 
 // Keep this extension always active!
 setExtensionAlwaysActive('Y');
@@ -733,6 +733,14 @@ INDEX (`ip`)
                                // Update notes (these will be set as task text!)
                                setExtensionUpdateNotes("IP-Resolver-Klasse hinzugef&uuml;gt, um bei der Erweiterung ext-network DNS-Anfragen einzusparen.");
                                break;
+
+                       case '0.7.1': // SQL queries for v0.7.1
+                               // This update just depends on ext-timezone to make integration of an essential extension much easier
+                               addExtensionUpdateDependency('timezone');
+
+                               // Update notes (these will be set as task text!)
+                               setExtensionUpdateNotes("Zeitzone ist nun mit ext-timezone konfigurierbar.");
+                               break;
                } // END - switch
                break;
 
index 8545512..10fff0f 100644 (file)
@@ -43,10 +43,10 @@ if (!defined('__SECURITY')) {
 } // END - if
 
 // Version number
-setThisExtensionVersion('0.1.1');
+setThisExtensionVersion('0.1.2');
 
 // Version history array (add more with , '0.1.0' and so on)
-setExtensionVersionHistory(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1'));
+setExtensionVersionHistory(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2'));
 
 switch (getExtensionMode()) {
        case 'register': // Do stuff when installation is running (modules.php?module=admin is called)
@@ -136,7 +136,6 @@ INDEX (`theme_active`)
                                addAdminMenuSql('theme', NULL, 'Themes','Verwalten Sie hier alle Designs (Themes) Ihres {OPEN_CONFIG}mt_word2{CLOSE_CONFIG}.', 8);
                                addAdminMenuSql('theme','theme_import','Importieren','Es wird das Verzeichnis &quot;theme&quot; nach neuen Ordnern durchsucht und anschliessend in die Datenbank gesperrt aufgenommen.', 1);
                                addAdminMenuSql('theme','theme_edit','Modifizieren','&Auml;ndern Sie Titel, Freigaben usw. an den Themes. Sie k&ouml;nnen bis auf das Standart-Theme &quot;default&quot; auch Themes aus der Datenbank entfernen. Vorher sollten Sie es jedoch vom Server l&ouml;schen, damit es niht erneut importiert werden kann.', 2);
-                               addAdminMenuSql('theme','theme_check','Pr&uuml;fen','Nach neuen Themes suchen bzw. nach Updates zu den Themes suchen.', 3);
 
                                // Guest menu
                                addGuestMenuSql('themes',NULL,'Design-Auswahl','Y','N',4);
@@ -177,6 +176,14 @@ INDEX (`theme_active`)
                                // Update notes (these will be set as task text!)
                                setExtensionUpdateNotes("Setzen des Mitgliedes&#39; eigener Design-Auswahl per Filter (internes TODO).");
                                break;
+
+                       case '0.1.2': // SQL queries for v0.1.2
+                               // Remove deprecated menu
+                               addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `what`='theme_check' LIMIT 1");
+
+                               // Update notes (these will be set as task text!)
+                               setExtensionUpdateNotes("Nicht mehr ben&ouml;tigtes Men&uuml; zum Pr&uuml;fen von Theme-Versionen entfernt.");
+                               break;
                } // END - switch
                break;
 
diff --git a/inc/extensions/ext-timezone.php b/inc/extensions/ext-timezone.php
new file mode 100644 (file)
index 0000000..6346b02
--- /dev/null
@@ -0,0 +1,111 @@
+<?php
+/************************************************************************
+ * Mailer v0.2.1-FINAL                                Start: 06/28/2010 *
+ * ===================                          Last change: 06/28/2010 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : ext-timezone.php                                 *
+ * -------------------------------------------------------------------- *
+ * Short description : Extension for changing timezone                  *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Erweiterung zum Aendern der Zeitzone             *
+ * -------------------------------------------------------------------- *
+ * $Revision::                                                        $ *
+ * $Date::                                                            $ *
+ * $Tag:: 0.2.1-FINAL                                                 $ *
+ * $Author::                                                          $ *
+ * Needs to be in all Files and every File needs "svn propset           *
+ * svn:keywords Date Revision" (autoprobset!) at least!!!!!!            *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2009 by Roland Haeder                           *
+ * Copyright (c) 2009, 2010 by Mailer Developer Team                    *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program 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 License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program 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 this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if (!defined('__SECURITY')) {
+       die();
+} // END - if
+
+// Version number
+setThisExtensionVersion('0.0');
+
+// Version history array (add more with , '0.1.0' and so on)
+setExtensionVersionHistory(array('0.0'));
+
+// Keep this extension always active!
+setExtensionAlwaysActive('Y');
+
+switch (getExtensionMode()) {
+       case 'register': // Do stuff when installation is running (modules.php?module=admin is called)
+               addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `timezone` VARCHAR(255) NOT NULL DEFAULT 'Europe/Berlin'");
+               addAdminMenuSql('setup','config_timezone','Zeitzone','Einstellungen an der Zeitzone k&ouml;nnen hier konfiguriert werden.',10);
+
+               // Register filter
+               registerFilter('init', 'INIT_TIMEZONE', false, true, getExtensionDryRun());
+               break;
+
+       case 'remove': // Do stuff when removing extension
+               // Remove admin menu
+               addExtensionSQL("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `what`='config_timezone' LIMIT 1");
+
+               // Unregister filter
+               unregisterFilter('init', 'INIT_TIMEZONE', true, getExtensionDryRun());
+               break;
+
+       case 'activate': // Do stuff when admin activates this extension
+               // SQL commands to run
+               addExtensionSql('');
+               break;
+
+       case 'deactivate': // Do stuff when admin deactivates this extension
+               // SQL commands to run
+               addExtensionSql('');
+               break;
+
+       case 'update': // Update an extension
+               switch (getCurrentExtensionVersion()) {
+                       case '0.0.1': // SQL queries for v0.0.1
+                               addExtensionSql("");
+
+                               // Update notes (these will be set as task text!)
+                               setExtensionUpdateNotes("Beschreinungstext des Updates.");
+                               break;
+
+                               // Update notes (these will be set as task text!)
+                               setExtensionUpdateNotes("Filter zum Zur&uuml;cksetzens des fehlgeschlagenen Mitgliederlogins hinzugef&uuml;gt (internes TODO).");
+                               break;
+               } // END - switch
+               break;
+
+       case 'modify': // When the extension got modified
+               break;
+
+       case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+               break;
+
+       case 'init': // Do stuff when extension is initialized
+               break;
+
+       default: // Unknown extension mode
+               logDebugMessage(__FILE__, __LINE__, sprintf("Unknown extension mode %s in extension %s detected.", getExtensionMode(), getCurrentExtensionName()));
+               break;
+} // END - switch
+
+// [EOF]
+?>
diff --git a/inc/language/timezone_de.php b/inc/language/timezone_de.php
new file mode 100644 (file)
index 0000000..94c0d47
--- /dev/null
@@ -0,0 +1,52 @@
+<?php
+/************************************************************************
+ * Mailer v0.2.1-FINAL                                Start: 06/28/2010 *
+ * ===================                          Last change: 06/28/2010 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : timezone_de.php                                  *
+ * -------------------------------------------------------------------- *
+ * Short description : German langugage support                         *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Deutsche Sprachunterstuetzung                    *
+ * -------------------------------------------------------------------- *
+ * $Revision::                                                        $ *
+ * $Date::                                                            $ *
+ * $Tag:: 0.2.1-FINAL                                                 $ *
+ * $Author::                                                          $ *
+ * Needs to be in all Files and every File needs "svn propset           *
+ * svn:keywords Date Revision" (autoprobset!) at least!!!!!!            *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2009 by Roland Haeder                           *
+ * Copyright (c) 2009, 2010 by Mailer Developer Team                    *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program 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 License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program 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 this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if (!defined('__SECURITY')) {
+       die();
+} // END - if
+
+// Language definitions
+addMessages(array(
+       'ADMIN_EDIT_TIMEZONE_SETTINGS' => "Konfiguration der Zeitzone",
+       'ADMIN_CONFIG_TIMEZONE' => "Zeitzone einstellen (z.B. Europe/Berlin):",
+));
+
+// [EOF]
+?>
index ef2d07b..a6f61c9 100644 (file)
@@ -122,9 +122,9 @@ function getThemeVersion ($name) {
        $cver = '?.?';
 
        // Is the cache entry there?
-       if (isset($GLOBALS['cache_array']['themes']['theme_ver'][$name])) {
+       if (isset($GLOBALS['cache_array']['themes']['theme_version'][$name])) {
                // Get the version from cache
-               $cver = $GLOBALS['cache_array']['themes']['theme_ver'][$name];
+               $cver = $GLOBALS['cache_array']['themes']['theme_version'][$name];
 
                // Count up
                incrementStatsEntry('cache_hits');
diff --git a/inc/libs/timezone_functions.php b/inc/libs/timezone_functions.php
new file mode 100644 (file)
index 0000000..c00d3d6
--- /dev/null
@@ -0,0 +1,55 @@
+<?php
+/************************************************************************
+ * Mailer v0.2.1-FINAL                                Start: 06/28/2010 *
+ * ===================                          Last change: 06/28/2010 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : timezone_functions.php                           *
+ * -------------------------------------------------------------------- *
+ * Short description : Functions for ext-timezone                       *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Funktionen fuer ext-timezone                     *
+ * -------------------------------------------------------------------- *
+ * $Revision::                                                        $ *
+ * $Date::                                                            $ *
+ * $Tag:: 0.2.1-FINAL                                                 $ *
+ * $Author::                                                          $ *
+ * Needs to be in all Files and every File needs "svn propset           *
+ * svn:keywords Date Revision" (autoprobset!) at least!!!!!!            *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2009 by Roland Haeder                           *
+ * Copyright (c) 2009, 2010 by Mailer Developer Team                    *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program 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 License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program 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 this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if (!defined('__SECURITY')) {
+       die();
+} // END - if
+
+// Filter for setting the timezone
+function FILTER_INIT_TIMEZONE () {
+       // Just set it if the required function is there
+       if (function_exists('date_default_timezone_set')) {
+               // CFG: TIME-ZONE
+               date_default_timezone_set(getConfig('timezone'));
+       } // END - if
+}
+
+// [EOF]
+?>
index 57f7a55..5566979 100644 (file)
@@ -55,14 +55,6 @@ if (isFormSent()) {
                loadTemplate('admin_settings_saved', false, getMessage('ADMIN_PROXY_SETTINGS_INVALID'));
        }
 } else {
-       // Prepare content
-       $content = array(
-               'proxy_host'     => getConfig('proxy_host'),
-               'proxy_port'     => getConfig('proxy_port'),
-               'proxy_username' => getConfig('proxy_username'),
-               'proxy_password' => getConfig('proxy_password'),
-       );
-
        // Load template
        loadTemplate('admin_config_proxy', false, $content);
 }
diff --git a/inc/modules/admin/what-config_timezone.php b/inc/modules/admin/what-config_timezone.php
new file mode 100644 (file)
index 0000000..b7fea78
--- /dev/null
@@ -0,0 +1,57 @@
+<?php
+/************************************************************************
+ * Mailer v0.2.1-FINAL                                Start: 06/28/2010 *
+ * ===================                          Last change: 06/28/2010 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : what-config_timezone.php                         *
+ * -------------------------------------------------------------------- *
+ * Short description : Configuration for                                *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Konfiguration der                                *
+ * -------------------------------------------------------------------- *
+ * $Revision::                                                        $ *
+ * $Date::                                                            $ *
+ * $Tag:: 0.2.1-FINAL                                                 $ *
+ * $Author::                                                          $ *
+ * Needs to be in all Files and every File needs "svn propset           *
+ * svn:keywords Date Revision" (autoprobset!) at least!!!!!!            *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2009 by Roland Haeder                           *
+ * Copyright (c) 2009, 2010 by Mailer Developer Team                    *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program 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 License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program 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 this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if ((!defined('__SECURITY')) || (!isAdmin())) {
+       die();
+} // END - if
+
+// Add description as navigation point
+addMenuDescription('admin', __FILE__);
+
+if (isFormSent()) {
+       // Save data
+       adminSaveSettingsFromPostData();
+} else {
+       // Load template
+       loadTemplate('admin_config_timezone');
+}
+
+// [EOF]
+?>
index 153d93a..f551ef4 100644 (file)
@@ -1,159 +1,3 @@
 <?php
-/************************************************************************
- * Mailer v0.2.1-FINAL                                Start: 03/22/2004 *
- * ===================                          Last change: 12/13/2004 *
- *                                                                      *
- * -------------------------------------------------------------------- *
- * File              : what-extentions.php                              *
- * -------------------------------------------------------------------- *
- * Short description : Extension management                             *
- * -------------------------------------------------------------------- *
- * Kurzbeschreibung  : Erweiterungen-Management                         *
- * -------------------------------------------------------------------- *
- * $Revision::                                                        $ *
- * $Date::                                                            $ *
- * $Tag:: 0.2.1-FINAL                                                 $ *
- * $Author::                                                          $ *
- * Needs to be in all Files and every File needs "svn propset           *
- * svn:keywords Date Revision" (autoprobset!) at least!!!!!!            *
- * -------------------------------------------------------------------- *
- * Copyright (c) 2003 - 2009 by Roland Haeder                           *
- * Copyright (c) 2009, 2010 by Mailer Developer Team                    *
- * For more information visit: http://www.mxchange.org                  *
- *                                                                      *
- * This program 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 License, or    *
- * (at your option) any later version.                                  *
- *                                                                      *
- * This program 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 this program; if not, write to the Free Software          *
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
- * MA  02110-1301  USA                                                  *
- ************************************************************************/
-
-// Some security stuff...
-if ((!defined('__SECURITY')) || (!isAdmin())) {
-       die();
-} // END - if
-
-// Add description as navigation point
-addMenuDescription('admin', __FILE__);
-
-// Normally we want the overview of all registered theme_check
-$mode = 'overview';
-
-// Get response from our server
-$response = sendGetRequest('check-themes.php');
-
-// Are theme_check found?
-if (($response[count($response) - 1] == '[EOF]') && ($response[0] != '[EOF]')) {
-       // Ok, mark found and create the array
-       $themes = array(
-               'fname'  => array(), // File names
-               'fsize'  => array(), // File size
-               'fctime' => array(), // File creation timestamp
-               'infos'  => array(), // File informations (maybe loaded!)
-               'ver'    => array(), // Version number
-               'cver'   => array(), // Current version number
-       );
-
-       // Get count of theme_check for validation
-       $count = trim($response[count($response) - 2]);
-       foreach ($response as $idx => $value) {
-               $value = str_replace("\n", '', $value); $ver = '';
-
-               // Leave loop when data is invalid or EOF?
-               if ((substr($value, 0, 6) == 'theme-') && (substr($value, -4) == '.zip')) {
-                       // Extract name and version
-                       $name = substr($value, 6, -4);
-                       $ver  = trim(substr($response[$idx + 3], 4));
-
-                       // Load version
-                       $cver = getThemeVersion($name);
-
-                       // Is the theme already installed or not?
-                       if (($ver != $cver) && ($cver != '?') && ($cver != '!')) {
-                               // No, it isn't. So let's add this one!
-                               $themes['fname'][]  = $name;
-                               $themes['fsize'][]  = $response[$idx + 1];
-                               $themes['fctime'][] = $response[$idx + 2];
-                               $themes['ver'][]    = $ver;
-                               $themes['cver'][]   = $cver;
-
-                               // Extract language strings from reponse
-                               $langDummy = explode('[nl]', $response[$idx + 4]);
-                               $languages = array();
-                               $themeInfo = getMessage('ADMIN_EXTENSION_NO_INFO_FOUND');
-
-                               // Trim every data line
-                               foreach ($langDummy as $k => $v) {
-                                       $v = trim($v);
-                                       if (substr($v, 3) == '') $v = '---';
-                                       $langDummy[$k] = $v;
-                                       if ($v == 'xx:xx') break;
-                                       $languages[] = $v;
-                               } // END - foreach
-
-                               // If language is found stop searching on matching line
-                               foreach($languages as $search) {
-                                       if (substr($search, 0, 3) == (getLanguage().':')) { $themeInfo = substr($search, 3); break; }
-                               } // END - foreach
-
-                               // Add informations to array
-                               $themes['infos'][] = $themeInfo;
-                       } // END - if
-               } // END - if
-       } // END - foreach
-
-       // Ok, themes are on our server but maybe you have already installed them?
-       if (count($themes['fname']) > 0) {
-               // Sort array (I missed ver and cver here)
-               array_pk_sort($themes, array('cver', 'fname'), 0, 1);
-
-               // Extensions where found which are not downloaded and installed
-               $OUT = ''; $SW = 2; $totalSize = '0';
-               foreach ($themes['fname'] as $idx => $name) {
-                       // Prepare data
-                       $content = array(
-                               'sw'      => $SW,
-                               'index'   => ($idx + 1),
-                               'name'    => $name,
-                               'created' => generateDateTime($themes['fctime'][$idx], 2),
-                               'size'    => translateComma(round($themes['fsize'][$idx] / 1.024) / 1000),
-                               'version' => $themes['ver'][$idx],
-                               'current' => $themes['cver'][$idx],
-                               'infos'   => $themes['infos'][$idx],
-                       );
-
-                       // Load row template
-                       $OUT .= loadTemplate('admin_list_theme_row', true, $content);
-
-                       // Add total size
-                       $totalSize += $themes['fsize'][$idx];
-
-                       // Switch color
-                       $SW = 3 - $SW;
-               }
-               $content['rows']   = $OUT;
-               $content['total']  = count($themes['fname']);
-               $content['kbytes'] = translateComma(round($totalSize / 1.024) / 1000);
-
-               // Load template
-               loadTemplate('admin_list_theme', false, $content);
-       } else {
-               // All Themes are downloaded and installed
-               loadTemplate('admin_theme_installed', false, $count);
-       }
-} else {
-       // No theme where found
-       loadTemplate('admin_settings_saved', false, getMessage('ADMIN_THEME_NOTHING_FOUND'));
-}
-
-// [EOF]
+// @DEPRECATED
 ?>
index 88c6bea..cab6254 100644 (file)
@@ -129,15 +129,14 @@ if (SQL_NUMROWS($result) > 0) {
 
                // Prepare data for the row template
                $content = array(
-                       'sw'           => $SW,
-                       'id'           => $content['id'],
-                       'link'         => $LINK,
-                       'theme_name'   => $content['theme_name'],
-                       'theme_active' => $content['theme_active'],
-                       'email'        => '<a href="mailto:' . $GLOBALS['theme_data']['email'] . '?Subject=[Theme:] ' . $GLOBALS['theme_data']['name'] . ' (' . $content['theme_path'] . ')\>' . $GLOBALS['theme_data']['author'] . '</a>',
-                       'url_link'     => generateDerefererUrl($GLOBALS['theme_data']['url']),
-                       'url_title'    => $GLOBALS['theme_data']['url'],
-                       'theme_ver'    => $content['theme_ver'],
+                       'sw'            => $SW,
+                       'id'            => $content['id'],
+                       'link'          => $LINK,
+                       'theme_name'    => $content['theme_name'],
+                       'theme_active'  => $content['theme_active'],
+                       'email'         => '<a href="mailto:' . $GLOBALS['theme_data']['email'] . '?Subject=[Theme:] ' . $GLOBALS['theme_data']['name'] . ' (' . $content['theme_path'] . ')\>' . $GLOBALS['theme_data']['author'] . '</a>',
+                       'url'           => $GLOBALS['theme_data']['url'],
+                       'theme_version' => $content['theme_version'],
                );
 
                // Load row template and switch color
index 070a64b..3a1c48d 100644 (file)
@@ -99,7 +99,7 @@ $THEMES = array(
        'theme_author' => array(), // Theme author's name
        'theme_email'  => array(), // Author's email address
        'theme_url'    => array(), // URL were you can download it from
-       'theme_ver'    => array(), // Version number of theme
+       'theme_version'    => array(), // Version number of theme
 );
 
 // Read directory "themes"
@@ -119,7 +119,7 @@ foreach ($includes as $inc) {
        $THEMES['theme_author'][] = $GLOBALS['theme_data']['author'];
        $THEMES['theme_email'][]  = $GLOBALS['theme_data']['email'];
        $THEMES['theme_url'][]    = $GLOBALS['theme_data']['url'];
-       $THEMES['theme_ver'][]    = $GLOBALS['theme_data']['version'];
+       $THEMES['theme_version'][]    = $GLOBALS['theme_data']['version'];
 } // END - while
 
 // Sort array by Uni* name
@@ -139,15 +139,14 @@ foreach ($THEMES['theme_unix'] as $key => $unix) {
 
        // Prepare content
        $content = array(
-               'sw'      => $SW,
-               'unix'    => $unix,
-               'name'    => $THEMES['theme_name'][$key],
-               'email'   => $THEMES['theme_email'][$key],
-               'author'  => $THEMES['theme_author'][$key],
-               'link'    => generateDerefererUrl($THEMES['theme_url'][$key]),
-               'url'     => $THEMES['theme_url'][$key],
-               'version' => $THEMES['theme_ver'][$key],
-               'form'    => $formContent
+               'sw'            => $SW,
+               'unix'          => $unix,
+               'theme_name'    => $THEMES['theme_name'][$key],
+               'theme_email'   => $THEMES['theme_email'][$key],
+               'theme_author'  => $THEMES['theme_author'][$key],
+               'theme_url'     => $THEMES['theme_url'][$key],
+               'theme_version' => $THEMES['theme_version'][$key],
+               'form_content'  => $formContent
        );
 
        // Add row template
index b05034d..4995716 100644 (file)
@@ -74,7 +74,7 @@ $THEMES = array(
        'theme_author' => array(), // Theme author's name
        'theme_email'  => array(), // Author's email address
        'theme_url'    => array(), // URL were you can download it from
-       'theme_ver'    => array(), // Version number of theme
+       'theme_version'    => array(), // Version number of theme
 );
 
 // Read directory "themes"
@@ -91,12 +91,12 @@ foreach ($includes as $inc) {
                loadInclude($inc);
 
                // Add found theme to array
-               $THEMES['theme_unix'][]   = $dir;
-               $THEMES['theme_name'][]   = $GLOBALS['theme_data']['name'];
-               $THEMES['theme_author'][] = $GLOBALS['theme_data']['author'];
-               $THEMES['theme_email'][]  = $GLOBALS['theme_data']['email'];
-               $THEMES['theme_url'][]    = $GLOBALS['theme_data']['url'];
-               $THEMES['theme_ver'][]    = $GLOBALS['theme_data']['version'];
+               $THEMES['theme_unix'][]    = $dir;
+               $THEMES['theme_name'][]    = $GLOBALS['theme_data']['name'];
+               $THEMES['theme_author'][]  = $GLOBALS['theme_data']['author'];
+               $THEMES['theme_email'][]   = $GLOBALS['theme_data']['email'];
+               $THEMES['theme_url'][]     = $GLOBALS['theme_data']['url'];
+               $THEMES['theme_version'][] = $GLOBALS['theme_data']['version'];
        } // END - if
 } // END - while
 
@@ -124,7 +124,7 @@ foreach ($THEMES['theme_unix'] as $key => $unix) {
   <td class=\"switch_sw".$SW." bottom right\" align=\"center\">
     <a href=\"".generateDerefererUrl($THEMES['theme_url'][$key])."\" target=\"_blank\">".$THEMES['theme_url'][$key]."</a>
   </td>
-  <td class=\"switch_sw".$SW." bottom\" align=\"center\">v".$THEMES['theme_ver'][$key]."</td>
+  <td class=\"switch_sw".$SW." bottom\" align=\"center\">v".$THEMES['theme_version'][$key]."</td>
 </tr>\n";
        $SW = 3 - $SW;
 } // END - foreach
index 3953136..3aea7a4 100644 (file)
@@ -11,7 +11,7 @@
                        {--ADMIN_CONFIG_PROXY_HOST--}
                </td>
                <td>
-                       <input type="text" name="proxy_host" value="$content[proxy_host]" />
+                       <input type="text" name="proxy_host" value="{?proxy_host?}" />
                </td>
        </tr>
        <tr>
@@ -19,7 +19,7 @@
                        {--ADMIN_CONFIG_PROXY_PORT--}
                </td>
                <td>
-                       <input type="text" name="proxy_port" value="$content[proxy_port]" />
+                       <input type="text" name="proxy_port" value="{?proxy_port?}" />
                </td>
        </tr>
        <tr>
@@ -27,7 +27,7 @@
                        {--ADMIN_CONFIG_PROXY_USERNAME--}
                </td>
                <td>
-                       <input type="text" name="proxy_username" value="$content[proxy_username]" />
+                       <input type="text" name="proxy_username" value="{?proxy_username?}" />
                </td>
        </tr>
        <tr>
@@ -35,7 +35,7 @@
                        {--ADMIN_CONFIG_PROXY_PASSWORD--}
                </td>
                <td class="bottom">
-                       <input type="password" name="proxy_password" value="$content[proxy_password]" />
+                       <input type="password" name="proxy_password" value="{?proxy_password?}" />
                </td>
        </tr>
        <tr>
diff --git a/templates/de/html/admin/admin_config_timezone.tpl b/templates/de/html/admin/admin_config_timezone.tpl
new file mode 100644 (file)
index 0000000..be13ad3
--- /dev/null
@@ -0,0 +1,25 @@
+<div align="center">
+<form accept-charset="utf-8" action="{%url=modules.php?module=admin&amp;what=config_timezone%}" method="post">
+<table border="0" cellspacing="0" cellpadding="0" class="admin_table dashed">
+       <tr>
+               <td colspan="2" align="center" class="admin_title bottom">
+                       <strong>{--ADMIN_EDIT_TIMEZONE_SETTINGS--}</strong>
+               </td>
+       </tr>
+       <tr>
+               <td class="bottom" align="right" style="padding-right:10px">
+                       {--ADMIN_CONFIG_TIMEZONE--}
+               </td>
+               <td class="bottom">
+                       <input type="text" name="timezone" value="{?timezone?}" />
+               </td>
+       </tr>
+       <tr>
+               <td colspan="2" class="admin_footer">
+                       <input type="reset" class="admin_reset" value="{--CLEAR_FORM--}" />
+                       <input type="submit" name="ok" class="admin_submit" value="{--SAVE_SETTINGS--}" />
+               </td>
+       </tr>
+</table>
+</form>
+</div>
index 100e523..11f5d85 100644 (file)
@@ -1,25 +1 @@
-<table border="0" cellspacing="0" cellpadding="0" class="admin_table dashed" align="center">
-<tr>
-       <td colspan="5" align="center" class="admin_title bottom">
-               <strong>{--ADMIN_THEME_NEW_FOUND_TITLE--}:</strong>
-       </td>
-</tr>
-<tr>
-       <td align="center" width="5%" class="header_column bottom right">{--ID_SELECT--}</td>
-       <td align="center" width="35%" class="header_column bottom right">{--ADMIN_EXTENSION_DOWNLOAD_LINK--}</td>
-       <td align="center" width="30%" class="header_column bottom right">{--ADMIN_THEME_FILE_CTIME--}</td>
-       <td align="center" width="15%" class="header_column bottom right">{--ADMIN_EXTENSION_FILE_SIZE--}</td>
-       <td align="center" width="15%" class="header_column bottom">{--THEME_VERSION--}</td>
-</tr>
-$content[rows]
-<tr>
-       <td colspan="2" align="center" class="header_column right">
-               {--ADMIN_THEME_TOTAL_FOUND--}:
-               <strong>$content[total]</strong>
-       </td>
-       <td colspan="3" align="right" class="header_column">
-               {--ADMIN_EXTENSION_TOTAL_FSIZE--}:
-               <strong>$content[kbytes] {--KBYTES--}</strong>
-       </td>
-</tr>
-</table>
+<!-- @DEPRECATED //-->
index 3f4a8af..11f5d85 100644 (file)
@@ -1,13 +1 @@
-<tr>
-       <td align="center" class="switch_sw$content[sw] bottom right">$content[index].</td>
-       <td align="center" class="switch_sw$content[sw] bottom right"><a href="{?SERVER_URL?}/themes/theme-$content[name].zip">$content[name]</a></td>
-       <td align="center" class="switch_sw$content[sw] bottom right">$content[created]</td>
-       <td align="center" class="switch_sw$content[sw] bottom right">$content[size] {--KBYTES--}</td>
-       <td align="center" class="switch_sw$content[sw] bottom">$content[version] ($content[current])</td>
-</tr>
-<tr>
-       <td class="switch_sw$content[sw] bottom">&nbsp;</td>
-       <td colspan="4" class="switch_sw$content[sw] bottom">
-               <div class="tiny">$content[infos]</div>
-       </td>
-</tr>
+<!-- @DEPRECATED //-->
index a6d7ae2..7532662 100644 (file)
@@ -16,7 +16,7 @@
                $content[email]
        </td>
        <td class="switch_sw$content[sw] bottom right" align="center">
-               <a href="$content[url_link]" target="_blank">$content[url_title]</a>
+               <a href="{%pipe,generateDerefererUrl=$content[url]%}" target="_blank">$content[url]</a>
        </td>
        <td class="switch_sw$content[sw] bottom" align="center">
                v$content[theme_ver]
index 4c5891a..90ab827 100644 (file)
@@ -1,14 +1,14 @@
 <tr>
        <td class="switch_sw$content[sw] bottom right" align="center">$content[unix]</td>
-       <td class="switch_sw$content[sw] bottom right" align="center">$content[name]</td>
+       <td class="switch_sw$content[sw] bottom right" align="center">$content[theme_name]</td>
        <td class="switch_sw$content[sw] bottom right" align="center">
-               <a href="mailto:$content[email]?Subject=[Theme:] $content[name] ($content[unix])">$content[author]</a>
+               <a href="mailto:$content[theme_email]?Subject=[Theme:] $content[name] ($content[unix])">$content[theme_author]</a>
        </td>
        <td class="switch_sw$content[sw] bottom right" align="center">
-               <a href="$content[link]" target="_blank">$content[url]</a>
+               <a href="{%pipe,generateDerefererUrl=$content[theme_url]%}" target="_blank">$content[theme_url]</a>
        </td>
-       <td class="switch_sw$content[sw] bottom right" align="center">v$content[version]</td>
+       <td class="switch_sw$content[sw] bottom right" align="center">v$content[theme_ver]</td>
        <td class="switch_sw$content[sw] bottom" align="center">
-               $content[form]
+               $content[form_content]
        </td>
 </tr>
index 4b539e8..0dcac42 100644 (file)
@@ -1,3 +1,2 @@
 Diese Erweiterung ist das, was ihr Name sagt: Datenbank-Updates (daher
-SQL_Upgrades) noch einfacher als mit dem upgrade.php Script einspielen!
-Somit wird auch dies zum Kinderspiel.
+sql_patches) noch einfacher als mit dem upgrade.php Script einspielen.
diff --git a/templates/de/html/ext/ext_timezone.tpl b/templates/de/html/ext/ext_timezone.tpl
new file mode 100644 (file)
index 0000000..d44cbb4
--- /dev/null
@@ -0,0 +1,3 @@
+Erlaubt das &Auml;ndern der Zeitzone und sollte unbedingt installiert werden.
+Einige Funktionen Ihres {OPEN_CONFIG}MT_WORD2{CLOSE_CONFIG} k&ouml;nnten unter
+Umst&auml;nden ohne dieser Erweiterung nicht mehr korrekt funktionieren.