From 1d22c70e65e858422ee0d17a7612f4b5c0757a42 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Thu, 27 Dec 2012 01:40:28 +0000 Subject: [PATCH] AJAX installation is 'basicly finished' :) Plus I threw in a small christmas present (hint: see installer) --- .gitattributes | 3 + DOCS/TODOs.txt | 26 +-- inc/ajax/ajax_admin.php | 2 +- inc/ajax/ajax_installer.php | 129 ++++++++++++++- inc/extensions-functions.php | 57 +++++-- inc/extensions/ext-admins.php | 3 - inc/extensions/ext-autopurge.php | 3 - inc/extensions/ext-beg.php | 3 - inc/extensions/ext-bonus.php | 3 - inc/extensions/ext-cache.php | 3 - inc/extensions/ext-coupon.php | 3 +- inc/extensions/ext-doubler.php | 3 - inc/extensions/ext-holiday.php | 3 - inc/extensions/ext-mailid.php | 3 - inc/extensions/ext-nickname.php | 6 - inc/extensions/ext-rallye.php | 6 - inc/extensions/ext-refback.php | 3 - inc/extensions/ext-register.php | 9 - inc/extensions/ext-removeip.php | 3 - inc/extensions/ext-surfbar.php | 3 - inc/extensions/ext-task.php | 6 - inc/extensions/ext-transfer.php | 6 - inc/extensions/ext-user.php | 3 - inc/extensions/ext-wernis.php | 3 - inc/filter/register_filter.php | 2 +- inc/filters.php | 8 +- inc/install-functions.php | 86 +++++++++- inc/install-inc.php | 6 +- inc/install/install_page_3.php | 22 +-- inc/install/install_page_5.php | 6 +- inc/install/install_page_finalize.php | 24 +-- inc/language/install_de.php | 10 ++ inc/libs/admins_functions.php | 10 +- inc/libs/register_functions.php | 42 ++--- inc/libs/security_functions.php | 6 +- inc/libs/sponsor_functions.php | 16 +- inc/module-functions.php | 6 +- inc/modules/admin.php | 4 +- inc/modules/admin/admin-inc.php | 40 ++--- inc/modules/admin/what-admins_add.php | 4 +- inc/modules/admin/what-edit_sponsor.php | 8 +- inc/modules/admin/what-edit_user.php | 6 +- inc/modules/guest/what-extensions.php | 11 +- inc/modules/guest/what-register.php | 6 +- inc/modules/guest/what-sponsor_reg.php | 10 +- inc/modules/member/what-mydata.php | 4 +- inc/modules/sponsor/account.php | 12 +- inc/template-functions.php | 13 +- inc/wrapper-functions.php | 20 ++- js/ajax-common.js | 156 ++++++++++-------- js/install-common.js | 97 ++++++++--- js/install-data.js | 18 +- .../de/emails/admin/admin_sponsor_edit.tpl | 2 +- .../de/emails/member/member_mydata_notify.tpl | 2 +- templates/de/html/admin/admin_add_admins.tpl | 4 +- templates/de/html/admin/admin_add_sponsor.tpl | 4 +- .../de/html/admin/admin_add_tester_user.tpl | 4 +- .../de/html/admin/admin_edit_admins_row.tpl | 4 +- .../de/html/admin/admin_edit_sponsor_edit.tpl | 4 +- templates/de/html/admin/admin_edit_user.tpl | 4 +- templates/de/html/admin/admin_reg_form.tpl | 8 +- .../html/admin/admin_reset_password_form.tpl | 4 +- templates/de/html/ext/ext_lead.tpl | 33 ++-- templates/de/html/ext/ext_primera.tpl | 15 +- templates/de/html/guest/guest_register.tpl | 4 +- templates/de/html/guest/guest_sponsor_reg.tpl | 4 +- .../html/install/install_list_extensions.tpl | 17 ++ .../install/install_list_extensions_row.tpl | 17 ++ .../de/html/install/install_main_ajax.tpl | 15 +- templates/de/html/install/install_menu.tpl | 1 + templates/de/html/install/install_page2.tpl | 4 +- templates/de/html/install/install_page3.tpl | 8 +- .../html/install/install_page_extensions.tpl | 11 ++ .../de/html/install/install_selector.tpl | 2 +- templates/de/html/js/js_install_ajax.tpl | 2 +- .../de/html/member/member_mydata_edit.tpl | 4 +- .../de/html/sponsor/sponsor_account_form.tpl | 4 +- theme/business/css/ajax.css | 14 +- theme/business/css/general.css | 12 ++ theme/default/css/ajax.css | 14 +- theme/default/css/general.css | 15 +- theme/desert/css/ajax.css | 14 +- theme/desert/css/general.css | 11 ++ theme/org/css/ajax.css | 14 +- theme/org/css/general.css | 11 ++ theme/schleuder/css/general.css | 11 ++ theme/ship-simu/css/general.css | 11 ++ 87 files changed, 807 insertions(+), 446 deletions(-) create mode 100644 templates/de/html/install/install_list_extensions.tpl create mode 100644 templates/de/html/install/install_list_extensions_row.tpl create mode 100644 templates/de/html/install/install_page_extensions.tpl diff --git a/.gitattributes b/.gitattributes index 7664ed1696..929a5ea61b 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1871,6 +1871,8 @@ templates/de/html/install/install_fatal_table.tpl svneol=native#text/plain templates/de/html/install/install_finished.tpl svneol=native#text/plain templates/de/html/install/install_footer.tpl svneol=native#text/plain templates/de/html/install/install_header.tpl svneol=native#text/plain +templates/de/html/install/install_list_extensions.tpl svneol=native#text/plain +templates/de/html/install/install_list_extensions_row.tpl svneol=native#text/plain templates/de/html/install/install_main_ajax.tpl svneol=native#text/plain templates/de/html/install/install_main_plain.tpl svneol=native#text/plain templates/de/html/install/install_menu.tpl svneol=native#text/plain @@ -1882,6 +1884,7 @@ templates/de/html/install/install_page3.tpl svneol=native#text/plain templates/de/html/install/install_page5.tpl svneol=native#text/plain templates/de/html/install/install_page_base_data.tpl svneol=native#text/plain templates/de/html/install/install_page_database_config.tpl svneol=native#text/plain +templates/de/html/install/install_page_extensions.tpl svneol=native#text/plain templates/de/html/install/install_page_init.tpl svneol=native#text/plain templates/de/html/install/install_page_other_config.tpl svneol=native#text/plain templates/de/html/install/install_page_overview.tpl svneol=native#text/plain diff --git a/DOCS/TODOs.txt b/DOCS/TODOs.txt index cc3ed37918..208cd59d8f 100644 --- a/DOCS/TODOs.txt +++ b/DOCS/TODOs.txt @@ -45,7 +45,8 @@ ./inc/extensions/ext-nickname.php:52: // @TODO NOT NULL DEFAULT '' is bad practice, use NULL ./inc/extensions/ext-yoomedia.php:121: // @TODO Can this be moved into a database table? ./inc/extensions/ext-yoomedia.php:54:// @TODO Only deprecated when 'ext-network' is ready! setExtensionDeprecated('Y'); -./inc/extensions-functions.php:2201:// @TODO This should be rewrittten to allow, more development states, e.g. 'planing','alpha','beta','beta2','stable' +./inc/extensions-functions.php:2169: // @TODO Is this really neccessary? +./inc/extensions-functions.php:2220:// @TODO This should be rewrittten to allow, more development states, e.g. 'planing','alpha','beta','beta2','stable' ./inc/extensions-functions.php:436: // @TODO This redirect is still needed to register sql_patches! Please try to avoid it ./inc/extensions-functions.php:452:// @TODO Change from ext_id to ext_name (not just even the variable! ;-) ) ./inc/extensions-functions.php:592: // @TODO Extension is loaded, what next? @@ -62,7 +63,7 @@ ./inc/functions.php:2478:// @TODO cacheFiles is not yet supported ./inc/gen_sql_patches.php:95:// @TODO Rewrite this to a filter ./inc/header.php:66:// @TODO Find a way to not use direct module comparison -./inc/install-functions.php:402: // @TODO Comparing with DEFAULT_MAIN_TITLE doesn't work +./inc/install-functions.php:446: // @TODO Comparing with DEFAULT_MAIN_TITLE doesn't work ./inc/install-functions.php:97: // @TODO DEACTIVATED: changeDataInLocalConfigurationFile('OUTPUT-MODE', "setConfigEntry('OUTPUT_MODE', '", "');", postRequestElement('omode'), 0); ./inc/language/de.php:1147: // @TODO Rewrite these two constants ./inc/language/de.php:1163: // @TODO Rewrite these three constants @@ -70,7 +71,7 @@ ./inc/language/de.php:741:// @TODO Are these constants longer used? ./inc/language-functions.php:255: // @TODO These are all valid languages, again hard-coded ./inc/language-functions.php:44:// @TODO Rewrite all language constants to this function. -./inc/language/install_de.php:140: // @TODO Move this to e.g. ext-smtp +./inc/language/install_de.php:142: // @TODO Move this to e.g. ext-smtp ./inc/language/newsletter_de.php:13: * @TODO This language file is completely out-dated, please do no * ./inc/language/order_de.php:70: // @TODO Find better text ./inc/language/rallye_de.php:13: * @TODO Naming convention not applied for language strings * @@ -190,17 +191,17 @@ ./inc/mysql-manager.php:44:// @TODO Can we cache this? ./inc/purge/purge-inact.php:55: // @TODO Rewrite these if() blocks to a filter ./inc/revision-functions.php:168:// @TODO This function does also set and get in 'cache_array' -./inc/template-functions.php:1134: // @TODO Deprecate this thing -./inc/template-functions.php:1145: // @TODO Deprecate this thing -./inc/template-functions.php:1252: // @TODO This can be easily moved out after the merge from EL branch to this is complete -./inc/template-functions.php:1301: // @TODO Add a little more infos here -./inc/template-functions.php:1667:// @TODO Lame description for this function -./inc/template-functions.php:1689: // @TODO Move this in a filter +./inc/template-functions.php:1143: // @TODO Deprecate this thing +./inc/template-functions.php:1154: // @TODO Deprecate this thing +./inc/template-functions.php:1276: // @TODO This can be easily moved out after the merge from EL branch to this is complete +./inc/template-functions.php:1325: // @TODO Add a little more infos here +./inc/template-functions.php:1691:// @TODO Lame description for this function +./inc/template-functions.php:1713: // @TODO Move this in a filter ./inc/template-functions.php:200: * @TODO On some pages this is buggy -./inc/template-functions.php:2323: // @TODO Is this needed for e.g. $GLOBALS['template_content'] ? $this->setRawTemplateData($compactedContent); +./inc/template-functions.php:2347: // @TODO Is this needed for e.g. $GLOBALS['template_content'] ? $this->setRawTemplateData($compactedContent); ./inc/template-functions.php:288: // @TODO Remove these sanity checks if all is fine -./inc/template-functions.php:625:// @TODO $simple/$constants are deprecated -./inc/template-functions.php:723: // @TODO $userid is deprecated and should be removed from loadEmailTemplate() and replaced with $content[userid] in all templates +./inc/template-functions.php:634:// @TODO $simple/$constants are deprecated +./inc/template-functions.php:732: // @TODO $userid is deprecated and should be removed from loadEmailTemplate() and replaced with $content[userid] in all templates ./inc/wrapper-functions.php:3176: // @TODO Find a way to not use direct module comparison ./inc/wrapper-functions.php:512:// @TODO Do some more sanity check here ./inc/xml-functions.php:240: // @TODO Handle characters @@ -317,6 +318,7 @@ ./templates/de/html/admin/admin_reg_row.tpl:1: ./templates/de/html/admin/admin_reg.tpl:1: ./templates/de/html/admin/admin_theme_list.tpl:1: +./templates/de/html/ext/ext_primera.tpl:1: ./templates/de/html/fatal_footer.tpl:1: ./templates/de/html/fatal_header.tpl:1: ./templates/de/html/guest/guest_confirm_table.tpl:1: diff --git a/inc/ajax/ajax_admin.php b/inc/ajax/ajax_admin.php index 827af52ec4..f8db0fdd0e 100644 --- a/inc/ajax/ajax_admin.php +++ b/inc/ajax/ajax_admin.php @@ -104,7 +104,7 @@ function doAjaxAdminRequestContent () { setHttpStatus('200 OK'); } else { // Set 404 error - setHttpStatus('404 NOT FOUND'); + setHttpStatus('404 Not Found'); } } // END - if } diff --git a/inc/ajax/ajax_installer.php b/inc/ajax/ajax_installer.php index ecdc4bdebb..1fedf138f0 100644 --- a/inc/ajax/ajax_installer.php +++ b/inc/ajax/ajax_installer.php @@ -65,7 +65,7 @@ function establishAjaxInstallerDatabaseLink () { if (!SQL_SELECT_DB(getSession('mysql_dbase'), __FUNCTION__, __LINE__)) { // Could not be selected reportBug(__FUNCTION__, __LINE__, 'Could not select database ' . getSession('mysql_dbase')); - } elseif ((!isFileReadable(getPath() . 'install/tables.sql')) || (!isFileReadable(getPath() . 'install/menu-'.getLanguage().'.sql'))) { + } elseif ((!isFileReadable(getSession('base_path') . 'install/tables.sql')) || (!isFileReadable(getSession('base_path') . 'install/menu-'.getLanguage().'.sql'))) { // Installation area not found reportBug(__FUNCTION__, __LINE__, 'SQL dumps not found. Please extract ALL files from the archive or checkout all files out from SVN.'); } elseif (ifFatalErrorsDetected()) { @@ -139,6 +139,7 @@ function doAjaxInstallerFooterNavigation () { case 'database_config': case 'smtp_config': case 'other_config': + case 'extensions': array_push($enabledNavigations, 'previous'); case 'welcome': // Only 'next' works for welcome page array_push($enabledNavigations, 'next'); @@ -225,7 +226,7 @@ function doAjaxInstallerRequestContent () { setHttpStatus('200 OK'); } else { // Set 404 error - setHttpStatus('404 NOT FOUND'); + setHttpStatus('404 Not Found'); } } // END - if } @@ -241,8 +242,14 @@ function doAjaxInstallerChangeWarning () { // "Walk" through all elements $OUT = '
    '; foreach (explode(':', postRequestElement('elements')) as $element) { - // Add row - $OUT .= '
  1. {--INSTALLER_CHANGED_ELEMENT_' . strtoupper($element) . '--}
  2. '; + // Is it an extension? + if (substr($element, 0, 4) == 'ext_') { + // Add row for extension + $OUT .= '
  3. {%message=INSTALLER_CHANGED_ELEMENT_EXTENSION=' . str_replace('_', '-', $element) . '%}
  4. '; + } else { + // Add generic row + $OUT .= '
  5. {--INSTALLER_CHANGED_ELEMENT_' . strtoupper($element) . '--}
  6. '; + } } // END - foreach $OUT .= '
'; @@ -277,7 +284,7 @@ function doAjaxInstallerSaveChanges () { $currentTab = postRequestElement('tab'); // Remove some elements which should not be saved - foreach (array('do', 'level') as $removedElement) { + foreach (array('tab', 'do', 'level') as $removedElement) { // Remove this element from POST data unsetPostRequestElement($removedElement); } // END - foreach @@ -297,6 +304,7 @@ function doAjaxInstallerSaveChanges () { // Now set all remaining data in session foreach (postRequestArray() as $key => $value) { // Set it, if it is valid, else it will be added to $saveStatus (call-by-reference) + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'key=' . $key . ',value[' . gettype($value) . '=' . $value); $saveStatus['is_saved'] = ( // Is the data valid? (isInstallerDataValid($saveStatus, $key, $value)) @@ -307,7 +315,7 @@ function doAjaxInstallerSaveChanges () { // Save the overall status for below final check $isAllSaved = (($isAllSaved === TRUE) && ($saveStatus['is_saved'] === TRUE)); - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'key=' . $key . ',value=' . $value . ',is_saved=' . intval($saveStatus['is_saved']) . ',isAllSaved=' . intval($isAllSaved)); + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'key=' . $key . ',value[' . gettype($value) . '=' . $value . ',is_saved=' . intval($saveStatus['is_saved']) . ',isAllSaved=' . intval($isAllSaved)); } // END - foreach // 'is_saved' is still true? @@ -446,6 +454,21 @@ function doAjaxPrepareInstallerOtherConfig () { } // END - if } +// Prepare AJAX request 'extensions' +function doAjaxPrepareInstallerExtensions () { + // Is 'extensions' set? + if (!isSessionVariableSet('extensions')) { + /* + * At least ext-sql_patches and ext-task should be installed + *(ext-sql_patches is a must!) + */ + setSession('extensions', 'admins:sql_patches:task'); + } elseif (strpos(getSession('extensions'), 'sql_patches') === FALSE) { + // Add missing ext-sql_patches + setSession('extensions', getSession('extensions') . ':sql_patches'); + } +} + // Prepare AJAX request 'overview' function doAjaxPrepareInstallerOverview () { // 'tab' must always be set to create a post-check-callback @@ -548,6 +571,100 @@ function doAjaxInstallerStepImportTablesSql () { // Now run all queries through runFilterChain('run_sqls'); + + // Close SQL link + SQL_CLOSE(__FUNCTION__, __LINE__); +} + +// Call-back function to import menu SQL file +function doAjaxInstallerStepImportMenuSql () { + // Establish database link + establishAjaxInstallerDatabaseLink(); + + // Init SQL array + initSqls(); + + // Import tables.sql + importInstallSqlDump('menu-' . getLanguage()); + + // Are some SQLs found? + if (countSqls() == 0) { + // Abort here + reportBug(__FUNCTION__, __LINE__, '{--INSTALLER_SQL_IMPORT_FAILED--}'); + } // END - if + + // Now run all queries through + runFilterChain('run_sqls'); + + // Close SQL link + SQL_CLOSE(__FUNCTION__, __LINE__); +} + +// Call-back function to install some important extensions +function doAjaxInstallerStepInstallExtensions () { + // Only one element is required + if (!isSessionVariableSet('extensions')) { + // Some required session data is not set + reportBug(__FUNCTION__, __LINE__, 'Required session data for this step not found.'); + } // END - if + + // Establish database link + establishAjaxInstallerDatabaseLink(); + + // Get all extensions + $extensions = explode(':', getSession('extensions')); + + // Make sure ext-sql_patches is first + array_unshift($extensions, 'sql_patches'); + + // "Walk" through all extensions + foreach ($extensions as $key => $ext_name) { + // Is ext-sql_patches not at key=0? + if (($key == 0) && ($ext_name == 'sql_patches')) { + // Then skip this entry + continue; + } elseif ((!loadExtension($ext_name, 'test', '0.0.0', TRUE)) || (!registerExtension($ext_name, NULL))) { + // Didn't work + reportBug(__FUNCTION__, __LINE__, 'Cannot load/register extension ' . $ext_name . '.'); + } // END - if + } // END - foreach + + // Close SQL link + SQL_CLOSE(__FUNCTION__, __LINE__); +} + +// Call-back function to write local configuration file +function doAjaxInstallerStepWriteLocalConfig () { + // Is all set? + if (!isSessionDataSet(array('base_path', 'base_url', 'main_title', 'slogan', 'webmaster', 'mysql_host', 'mysql_dbase', 'mysql_prefix', 'mysql_login', 'mysql_password1', 'mysql_password2', 'mysql_engine', 'output_mode', 'warn_no_pass', 'write_footer', 'enable_backlink'))) { + // Some required session data is not set + reportBug(__FUNCTION__, __LINE__, 'Required session data for this step not found.'); + } // END - if + + // Write config file + if (!doInstallWriteLocalConfigurationFile( + getSession('base_path'), + getSession('base_url'), + getSession('main_title'), + getSession('slogan'), + getSession('webmaster'), + getSession('warn_no_pass'), + getSession('write_footer'), + getSession('enable_backlink'), + getSession('mysql_host'), + getSession('mysql_dbase'), + getSession('mysql_login'), + getSession('mysql_password1'), + getSession('mysql_prefix'), + getSession('mysql_engine'), + getSession('smtp_host'), + getSession('smtp_user'), + getSession('smtp_password1') + )) { + // Something bad went wrong + removeFile(getSession('base_path') . getCachePath() . 'config-local.php'); + reportBug(__FUNCTION__, __LINE__, 'Did not fully write config-local.php .'); + } } // [EOF] diff --git a/inc/extensions-functions.php b/inc/extensions-functions.php index 08346b041b..526552cd5b 100644 --- a/inc/extensions-functions.php +++ b/inc/extensions-functions.php @@ -201,7 +201,7 @@ function registerExtension ($ext_name, $taskId, $isDryRun = FALSE, $ignoreUpdate // When this extension is already in registration/update phase, all is fine if ((isExtensionRegistrationRunning($ext_name)) || ((isExtensionUpdateRunning($ext_name)) && ($ignoreUpdates === FALSE))) { // Then abort here with 'true' because it is fine - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'ext_name=' . $ext_name . ' - already in registration/update phase, all fine,isDryRun=' . intval($isDryRun) . ',ignoreUpdates=' . intval($ignoreUpdates)); + /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'ext_name=' . $ext_name . ' - already in registration/update phase, all fine,isDryRun=' . intval($isDryRun) . ',ignoreUpdates=' . intval($ignoreUpdates)); //* BUG: */ reportBug(__FUNCTION__, __LINE__, 'ext_name=' . $ext_name . ',isDryRun=' . intval($isDryRun) . ',ignoreUpdates=' . intval($ignoreUpdates) . ' - Please investigate!'); return TRUE; } // END - if @@ -1378,6 +1378,12 @@ function isExtensionUpdateDependenciesInitialized () { // Checks whether an update is already running for given extension function isExtensionUpdateRunning ($ext_name, $ignoreDependencies = FALSE) { + // 'ext_running_updates' must be there + if ((!isset($GLOBALS['ext_running_updates'])) || (!is_array($GLOBALS['ext_running_updates']))) { + // Is not there + reportBug(__FUNCTION__, __LINE__, 'Required array ext_running_updates not found. ext_name=' . $ext_name . ',ignoreDependencies=' . intval($ignoreDependencies)); + } // END - if + // Current and given extensions means whole array //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'currentExtension=' . getCurrentExtensionName() . ',ext_name=' . $ext_name . ',ignoreDependencies=' . intval($ignoreDependencies) . ' - ENTERED!'); if ($ext_name == getCurrentExtensionName()) { @@ -2158,18 +2164,31 @@ function registerExtensionPointsData ($subject, $columnName, $lockedMode, $payme //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'ifSqlTableExists(points_data)=' . ifSqlTableExists('points_data') . ',getExtensionMode()=' . getExtensionMode() . ',add=' . $add); if (((!ifSqlTableExists('points_data')) && ((getExtensionMode() == 'register') || (getExtensionMode() == 'update'))) || (countSumTotalData($subject, 'points_data', 'id', 'subject', TRUE, $add) == 0)) { // Not found so: - if ((isset($GLOBALS['previous_extension'][getCurrentExtensionName()])) && (!ifSqlTableExists('points_data'))) { + if ((!isInstallationPhase()) && (isset($GLOBALS['previous_extension'][getCurrentExtensionName()])) && (!ifSqlTableExists('points_data'))) { + // This may happen (but when?) + // @TODO Is this really neccessary? $dummy = $GLOBALS['previous_extension'][getCurrentExtensionName()]; reportBug(__FUNCTION__, __LINE__, 'previous_extension[' . gettype($dummy) . ']=' . $dummy . ',getCurrentExtensionName()=' . getCurrentExtensionName() . ' - Under development, please report this!'); } // END - if - // ... add an SQL query - addExtensionSql(sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('%s','%s','%s','%s')", - $subject, - $columnName, - $lockedMode, - $paymentMethod - )); + // With or without account_provider? + if (((isInstallationPhase()) && ((getExtensionMode() == 'register') || (getExtensionMode() == 'update'))) || (isExtensionInstalledAndNewer('sql_patches', '0.8.9'))) { + // Add account_provider + addExtensionSql(sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`, `account_provider`) VALUES ('%s','%s','%s','%s','EXTENSION')", + $subject, + $columnName, + $lockedMode, + $paymentMethod + )); + } else { + // ... add an SQL query + addExtensionSql(sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('%s','%s','%s','%s')", + $subject, + $columnName, + $lockedMode, + $paymentMethod + )); + } } // END - if } @@ -2280,7 +2299,7 @@ function copyExtensionDataToCacheArray ($ext_name, $ext_id) { $GLOBALS['cache_array']['extension']['ext_active'][$ext_name] = getThisExtensionAlwaysActive(); $GLOBALS['cache_array']['extension']['ext_lang'][$ext_name] = convertBooleanToYesNo(isExtensionLanguageFileReadable($ext_name)); $GLOBALS['cache_array']['extension']['ext_func'][$ext_name] = convertBooleanToYesNo(isExtensionFunctionFileReadable($ext_name)); - $GLOBALS['cache_array']['extension']['ext_menu'][$ext_name] = convertBooleanToYesNo(ifModuleHasMenu($ext_name)); + $GLOBALS['cache_array']['extension']['ext_menu'][$ext_name] = convertBooleanToYesNo(ifModuleHasMenu($ext_name, isInstallationPhase())); $GLOBALS['cache_array']['extension']['ext_css'][$ext_name] = convertBooleanToYesNo(getExtensionHasCss()); $GLOBALS['cache_array']['extension']['ext_deprecated'][$ext_name] = 'N'; } @@ -2298,5 +2317,23 @@ function isTaskIdValid ($taskId) { return $GLOBALS[__FUNCTION__][$taskId]; } +// "Getter" for "checked="checked" from given session data +function getExtensionSelectedFromSession ($ext_name, $sessionName, $separator = ':') { + // Get the data and explode it + $selections = explode($separator, getSession($sessionName)); + + // Default is not checked + $checked = ''; + + // Is it there? + if (in_array($ext_name, $selections)) { + // It is, so mark it + $checked = ' checked="checked"'; + } // END - if + + // Return result + return $checked; +} + // [EOF] ?> diff --git a/inc/extensions/ext-admins.php b/inc/extensions/ext-admins.php index d21465ce13..6a3d2ad6a3 100644 --- a/inc/extensions/ext-admins.php +++ b/inc/extensions/ext-admins.php @@ -291,9 +291,6 @@ INDEX (`admin_id`)", break; case '0.7.1': // SQL queries for v0.7.1 - // Update depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Add filters registerFilter(__FILE__, __LINE__, 'sql_admin_extra_data', 'ADD_EXTRA_SQL_DATA', FALSE, TRUE, isExtensionDryRun()); diff --git a/inc/extensions/ext-autopurge.php b/inc/extensions/ext-autopurge.php index 089757cae2..ba1ff9d801 100644 --- a/inc/extensions/ext-autopurge.php +++ b/inc/extensions/ext-autopurge.php @@ -260,9 +260,6 @@ switch (getExtensionMode()) { // Register with points data system registerExtensionPointsData('autopurge_add', 'points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Rückschriften bei Auto-Löschungen werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/extensions/ext-beg.php b/inc/extensions/ext-beg.php index 8d6f332cd6..e2c42c6957 100644 --- a/inc/extensions/ext-beg.php +++ b/inc/extensions/ext-beg.php @@ -316,9 +316,6 @@ INDEX (`userid`)", registerExtensionPointsData('beg' , 'points', 'LOCKED', 'DIRECT'); registerExtensionPointsData('monthly_beg', 'points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Monatliche Bettelrallye und die erbettelten {?POINTS?} werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/extensions/ext-bonus.php b/inc/extensions/ext-bonus.php index f8a87a665d..4ba29ce01f 100644 --- a/inc/extensions/ext-bonus.php +++ b/inc/extensions/ext-bonus.php @@ -617,9 +617,6 @@ ORDER BY // Register points data registerExtensionPointsData('monthly_bonus', 'points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Monatlicher Bonus wird nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/extensions/ext-cache.php b/inc/extensions/ext-cache.php index 152d58cba2..93bdb9b4bf 100644 --- a/inc/extensions/ext-cache.php +++ b/inc/extensions/ext-cache.php @@ -184,9 +184,6 @@ switch (getExtensionMode()) { break; case '0.2.0': // SQL queries for v0.2.0 - // This update depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Die Erweiterung hängt nun von der sql_patches ab."); break; diff --git a/inc/extensions/ext-coupon.php b/inc/extensions/ext-coupon.php index 664776bad8..0c6d128a35 100644 --- a/inc/extensions/ext-coupon.php +++ b/inc/extensions/ext-coupon.php @@ -137,8 +137,7 @@ UNIQUE INDEX (`coupon_code`)", addConfigDropSql('coupon_payment_method'); addConfigDropSql('coupon_locked_points_mode'); - // This extension's update requires an up-to-date ext-sql_patches and ext-order - addExtensionDependency('sql_patches'); + // This extension's update requires an up-to-date ext-order addExtensionDependency('order'); // Insert data in new table diff --git a/inc/extensions/ext-doubler.php b/inc/extensions/ext-doubler.php index 3736a67dc1..b3863245bc 100644 --- a/inc/extensions/ext-doubler.php +++ b/inc/extensions/ext-doubler.php @@ -247,9 +247,6 @@ INDEX (`userid`)", registerExtensionPointsData('doubler_direct', 'points', 'LOCKED', 'DIRECT'); registerExtensionPointsData('doubler_reset' , 'points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Doppler-Gutschriften werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/extensions/ext-holiday.php b/inc/extensions/ext-holiday.php index 0a984730fd..402f6a7ad8 100644 --- a/inc/extensions/ext-holiday.php +++ b/inc/extensions/ext-holiday.php @@ -191,9 +191,6 @@ INDEX (`userid`)", addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu_las` (`la_id`, `la_action`, `la_what`) VALUES ('member', '', 'del_holiday')"); addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu_las` (`la_id`, `la_action`, `la_what`) VALUES ('config', '', 'config_holiday')"); - // Depends on ext-sql_patches (or you have to execute these both SQL statements by phpMyAdmin - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Erweiterung in's neue Menüsystem integriert."); break; diff --git a/inc/extensions/ext-mailid.php b/inc/extensions/ext-mailid.php index 8e08cb8c7d..6eff793247 100644 --- a/inc/extensions/ext-mailid.php +++ b/inc/extensions/ext-mailid.php @@ -233,9 +233,6 @@ switch (getExtensionMode()) { break; case '0.3.4': // SQL queries for v0.3.4 - // This update depends on latest ext-sql_patches version - addExtensionDependency('sql_patches'); - // Register points data registerExtensionPointsData('mailid_payback', 'points', 'LOCKED', 'DIRECT'); break; diff --git a/inc/extensions/ext-nickname.php b/inc/extensions/ext-nickname.php index 34ea3f3e3f..e2bfaadfb4 100644 --- a/inc/extensions/ext-nickname.php +++ b/inc/extensions/ext-nickname.php @@ -76,9 +76,6 @@ switch (getExtensionMode()) { case 'update': // Update an extension switch (getCurrentExtensionVersion()) { case '0.0.1': // SQL queries for v0.0.1 - // This update depends on ext-sql_patches update! - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Veraltetes Update entfernt."); break; @@ -188,9 +185,6 @@ switch (getExtensionMode()) { // Remove this deprecated table addDropTableSql('nickname_history'); - // This update depends on ext-sql_patches update! - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Diese Tabelle kann in ext-sql_patches allgemeiner formuliert werden."); break; diff --git a/inc/extensions/ext-rallye.php b/inc/extensions/ext-rallye.php index da987bb239..4938bab43d 100644 --- a/inc/extensions/ext-rallye.php +++ b/inc/extensions/ext-rallye.php @@ -312,9 +312,6 @@ Zudem sollten Sie mindestens folgende Templates (in templates/".getLangu break; case '0.3.5': // SQL queries for 0.3.5 - // This update depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Register filter registerFilter(__FILE__, __LINE__, 'extra_autopurge', 'RALLYE_EXTRA_AUTOPURGE', FALSE, TRUE, isExtensionDryRun()); @@ -326,9 +323,6 @@ Zudem sollten Sie mindestens folgende Templates (in templates/".getLangu // Register points data registerExtensionPointsData('rallye_winner', 'points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Gewinn aus der Referral-Rallye wird nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/extensions/ext-refback.php b/inc/extensions/ext-refback.php index b6252421ea..8411f9580a 100644 --- a/inc/extensions/ext-refback.php +++ b/inc/extensions/ext-refback.php @@ -96,9 +96,6 @@ switch (getExtensionMode()) { // Register points data registerExtensionPointsData('refback', 'points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Refback-Gutschriften werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/extensions/ext-register.php b/inc/extensions/ext-register.php index 85bfcb4632..d31fbb0cb6 100644 --- a/inc/extensions/ext-register.php +++ b/inc/extensions/ext-register.php @@ -105,17 +105,11 @@ PRIMARY KEY (`id`)", break; case '0.1.1': // SQL queries for v0.1.1 - // This update depends on ext-sql_patches update! - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Veraltetes Update entfernt."); break; case '0.1.3': // SQL queries for v0.1.3 - // This update depends on ext-sql_patches update! - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Standard Referral-Id kann per Admin-Bereich eingestellt werden (war vorher nur in modules.php und index.php direkt eingebbar.)"); break; @@ -351,9 +345,6 @@ PRIMARY KEY (`id`)", // Register points data registerExtensionPointsData('register_welcome', 'points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Anmeldewillkommensgutschrift wird nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/extensions/ext-removeip.php b/inc/extensions/ext-removeip.php index f258946227..6783fd3b10 100644 --- a/inc/extensions/ext-removeip.php +++ b/inc/extensions/ext-removeip.php @@ -80,9 +80,6 @@ switch (getExtensionMode()) { case 'update': // Update an extension switch (getCurrentExtensionVersion()) { case '0.0.1': // SQL queries for v0.0.1 - // Update depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Add filters registerFilter(__FILE__, __LINE__, 'post_youhere_line', 'ADD_ANONYMITY_NOTICE', FALSE, TRUE, isExtensionDryRun()); diff --git a/inc/extensions/ext-surfbar.php b/inc/extensions/ext-surfbar.php index f64e173b6c..84394b9cf0 100644 --- a/inc/extensions/ext-surfbar.php +++ b/inc/extensions/ext-surfbar.php @@ -215,9 +215,6 @@ UNIQUE INDEX `status_action` (`actions_status`, `actions_action`)", // Insert data for points accounts registerExtensionPointsData('monthly_surfbar', 'points', 'LOCKED', 'DIRECT'); - // This extension depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Register filters registerFilter(__FILE__, __LINE__, 'post_change_surfbar_url_status', 'SURFBAR_CHANGE_URL_STATUS', FALSE, TRUE, isExtensionDryRun()); registerFilter(__FILE__, __LINE__, 'pre_change_surfbar_url_status', 'SURFBAR_CHANGE_URL_VALIDATE_DATA', FALSE, TRUE, isExtensionDryRun()); diff --git a/inc/extensions/ext-task.php b/inc/extensions/ext-task.php index 29945d6c92..b711688985 100644 --- a/inc/extensions/ext-task.php +++ b/inc/extensions/ext-task.php @@ -82,9 +82,6 @@ switch (getExtensionMode()) { case 'update': // Update an extension switch (getCurrentExtensionVersion()) { case '0.0.1': // SQL queries for v0.0.1 - // This update depends on ext-sql_patches update! - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Veraltetes Update entfernt."); break; @@ -242,9 +239,6 @@ switch (getExtensionMode()) { break; case '0.3.2': // SQL queries for v0.3.2 - // This update depends on user update - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Hängt nun von ext-user ab."); break; diff --git a/inc/extensions/ext-transfer.php b/inc/extensions/ext-transfer.php index 7f06be7750..a1f480f7e1 100644 --- a/inc/extensions/ext-transfer.php +++ b/inc/extensions/ext-transfer.php @@ -234,9 +234,6 @@ INDEX (`to_userid`)", addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu_las` (`la_id`, `la_action`, `la_what`) VALUES ('member', '', 'del_transfer')"); addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu_las` (`la_id`, `la_action`, `la_what`) VALUES ('config', '', 'config_transfer')"); - // Depends on ext-sql_patches (or you have to execute these both SQL statements by phpMyAdmin - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Erweiterung in's neue Menüsystem integriert."); break; @@ -277,9 +274,6 @@ INDEX (`to_userid`)", // Register points data registerExtensionPointsData('transfer', 'points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Ünerweisungen anderer Mitglieder werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/extensions/ext-user.php b/inc/extensions/ext-user.php index de7aab71a4..d1eb6d75c4 100644 --- a/inc/extensions/ext-user.php +++ b/inc/extensions/ext-user.php @@ -222,9 +222,6 @@ INDEX (`stats_type`)", break; case '0.1.1': // SQL queries for v0.1.1 - // This update depends on ext-sql_patches update! - addExtensionDependency('sql_patches'); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Ungültiges Update."); break; diff --git a/inc/extensions/ext-wernis.php b/inc/extensions/ext-wernis.php index 0e566ccba1..14202df9df 100644 --- a/inc/extensions/ext-wernis.php +++ b/inc/extensions/ext-wernis.php @@ -142,9 +142,6 @@ INDEX (`userid`)", // Register points data registerExtensionPointsData('wernis_withdraw', 'order_points', 'LOCKED', 'DIRECT'); - // This depends on ext-sql_patches - addExtensionDependency('sql_patches'); - // Update notes setExtensionUpdateNotes("Überweisungen vom Portal werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); break; diff --git a/inc/filter/register_filter.php b/inc/filter/register_filter.php index 14adc971c1..655ee8caa5 100644 --- a/inc/filter/register_filter.php +++ b/inc/filter/register_filter.php @@ -90,7 +90,7 @@ function FILTER_PRE_USER_REGISTRATION_GENERIC ($filterData) { postRequestElement('month') . '-' . postRequestElement('day') . '-' . postRequestElement('year') . getEncryptSeparator() . - postRequestElement('pass1') . getEncryptSeparator() . + postRequestElement('password1') . getEncryptSeparator() . detectServerName() . getEncryptSeparator() . detectRemoteAddr() . getEncryptSeparator() . detectUserAgent() . '/' . diff --git a/inc/filters.php b/inc/filters.php index 668eaa2f25..8c885c5006 100644 --- a/inc/filters.php +++ b/inc/filters.php @@ -54,8 +54,8 @@ function FILTER_FLUSH_FILTERS () { return; } - // Is the extension ext-sql_patches updated and not in installation phase? - if ((!isInstallationPhase()) && ((!isExtensionInstalled('sql_patches')) || (isExtensionInstalledAndOlder('sql_patches', '0.5.9')))) { + // Is the extension ext-sql_patches updated? + if ((!isExtensionInstalled('sql_patches')) || (isExtensionInstalledAndOlder('sql_patches', '0.5.9'))) { // Log only in debug mode if (isDebugModeEnabled()) { logDebugMessage(__FUNCTION__, __LINE__, 'Cannot flush filters, ext-sql_patches might be missing. isExtensionInstalled()=' . intval(isExtensionInstalled('sql_patches')) . ',isExtensionInstalledAndOlder()=' . intval(isExtensionInstalledAndOlder('sql_patches', '0.5.9'))); @@ -565,8 +565,8 @@ function FILTER_COMPILE_EXPRESSION_CODE ($filterData) { } // END - foreach } // END - if - // Is there non-HTML mode? - if (!isHtmlOutputMode()) { + // Is there non-HTML/AJAX mode? + if ((!isHtmlOutputMode()) && (!isAjaxOutputMode())) { $filterData = decodeEntities($filterData); } // END - if diff --git a/inc/install-functions.php b/inc/install-functions.php index ef8ae8debb..f6d75436b9 100644 --- a/inc/install-functions.php +++ b/inc/install-functions.php @@ -109,7 +109,7 @@ function doInstallWriteLocalConfigurationFile ($path, $url, $title, $slogan, $em changeDataInLocalConfigurationFile('SITE-KEY', "setConfigEntry('SITE_KEY', '", "');", generatePassword(50), 0); // Script is now installed - changeDataInLocalConfigurationFile('INSTALLED', "setConfigEntry('MAILER_INSTALLED', '", "');", 'Y', 0); + return changeDataInLocalConfigurationFile('INSTALLED', "setConfigEntry('MAILER_INSTALLED', '", "');", 'Y', 0); } // Adds a given template with content to install output stream @@ -253,7 +253,7 @@ function isInstallerDataValid (&$saveStatus, $key, $value) { } // END - if // Then call it back - $isValid = (bool) call_user_func($callbackName, trim($value)); + $isValid = (bool) call_user_func($callbackName, $value); // Is it not valid? //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'key=' . $key . ',value=' . $value . ',isValid=' . intval($isValid)); @@ -335,6 +335,50 @@ function addKeyValueToInstallerOverviewGroup ($key, $value) { $GLOBALS['installer_overview'][$group][$key] = $value; } +//----------------------------------------------------------------------------- +// Template call-back functions +//----------------------------------------------------------------------------- + +// ----------------- Extensions ----------------- + +// Generates (and returns) a table from all extensions +function generateInstallerExtensionTable () { + // Generate extension list + $extensions = loadAllExtensionsByTemplate(); + + // "Walk" through all + $OUT = ''; + foreach ($extensions as $extension) { + // Remove prefix + suffix + $ext_name = substr(basename($extension), 4, -4); + + // Is the extension not in development and not admintheme* ? + if ((loadExtension($ext_name, 'test', '0.0.0', TRUE)) && (isExtensionProductive($ext_name)) && (substr($ext_name, 0, 10) != 'admintheme')) { + // Default is not disabled + $disabled = ''; + if ($ext_name == 'sql_patches') { + // Always keep this enabled + $disabled = ' disabled="disabled"'; + } // END - if + + // Initialize content array + $content = array( + 'ext_name' => $ext_name, + 'ext_version' => getExtensionVersion($ext_name), + 'checked' => getExtensionSelectedFromSession($ext_name, 'extensions'), + 'disabled' => $disabled, + 'description' => loadTemplate('ext_' . $ext_name, TRUE), + ); + + // Load row template + $OUT .= loadTemplate('install_list_extensions_row', TRUE, $content); + } // END - if + } // END - foreach + + // Load main template + return loadTemplate('install_list_extensions', TRUE, $OUT); +} + //----------------------------------------------------------------------------- // Call-back functions to check validity //----------------------------------------------------------------------------- @@ -497,6 +541,44 @@ function isInstallerMysqlPrefixValid ($value) { // ----------------- Other configuration ----------------- +// ----------------- Extensions ----------------- + +// Call-back function to check 'sel' (array!) +function isInstallerSelValid ($value) { + // $value is not an array, is really bad. + if (!is_array($value)) { + // Is no array + reportBug(__FUNCTION__, __LINE__, 'sel,value[]=' . gettype($value) . '!=array'); + } // END - if + + // Add always missing ext-sql_patches + $value['sql_patches'] = '1'; + + // Default is fine + $isValid = TRUE; + + // "Walk" through all extensions + foreach ($value as $ext_name => $sel) { + // Is this extension choosen? + if ($sel != '1') { + // Skip this + continue; + } // END - if + + // Can it be loaded? + $isValid = (($isValid) && (loadExtension($ext_name, 'test', '0.0.0', TRUE))); + } // END - foreach + + // Remove 'sel' from POST data as it cannot be saved + unsetPostRequestElement('sel'); + + // Save it in session (sorry to do that here :( ) + setSession('extensions', implode(':', array_keys($value))); + + // Return result + return $isValid; +} + //----------------------------------------------------------------------------- // Call-back functions to post-check validity //----------------------------------------------------------------------------- diff --git a/inc/install-inc.php b/inc/install-inc.php index 1e00d24106..5782a99fd2 100644 --- a/inc/install-inc.php +++ b/inc/install-inc.php @@ -67,19 +67,19 @@ if ((isGetRequestElementSet('install_page') && (getRequestElement('install_page' setGetRequestElement('install_page', 3); } // END - if - if ((!isPostRequestElementSet('smtp_pass1')) && (isPostRequestElementSet('smtp_pass2'))) { + if ((!isPostRequestElementSet('smtp_password1')) && (isPostRequestElementSet('smtp_password2'))) { // Password is empty addToInstallContent('
{--INSTALLER_SMTP_PASSWORD1_EMPTY--}
'); setGetRequestElement('install_page', 3); } // END - if - if ((isPostRequestElementSet('smtp_pass1')) && (!isPostRequestElementSet('smtp_pass2'))) { + if ((isPostRequestElementSet('smtp_password1')) && (!isPostRequestElementSet('smtp_password2'))) { // Password repeat is empty addToInstallContent('
{--INSTALLER_SMTP_PASSWORD2_EMPTY--}
'); setGetRequestElement('install_page', 3); } // END - if - if (postRequestElement('smtp_pass1') != postRequestElement('smtp_pass1')) { + if (postRequestElement('smtp_password1') != postRequestElement('smtp_password1')) { // Passwords are not matching addToInstallContent('
{--INSTALLER_SMTP_PASS_MISMATCH--}
'); setGetRequestElement('install_page', 3); diff --git a/inc/install/install_page_3.php b/inc/install/install_page_3.php index 2bdfb00013..182bb87d5a 100644 --- a/inc/install/install_page_3.php +++ b/inc/install/install_page_3.php @@ -62,19 +62,19 @@ if (isPostRequestElementSet('smtp_pass')) { } // END - if // Database login data -$content['mysql_host'] = $GLOBALS['install_mysql']['host']; -$content['mysql_dbase'] = $GLOBALS['install_mysql']['dbase']; -$content['mysql_prefix'] = $GLOBALS['install_mysql']['prefix']; -$content['table_type'] = $GLOBALS['install_mysql']['type']; -$content['mysql_login'] = $GLOBALS['install_mysql']['login']; -$content['mysql_pass1'] = $GLOBALS['install_mysql']['pass1']; -$content['mysql_pass2'] = $GLOBALS['install_mysql']['pass2']; +$content['mysql_host'] = $GLOBALS['install_mysql']['host']; +$content['mysql_dbase'] = $GLOBALS['install_mysql']['dbase']; +$content['mysql_prefix'] = $GLOBALS['install_mysql']['prefix']; +$content['table_type'] = $GLOBALS['install_mysql']['type']; +$content['mysql_login'] = $GLOBALS['install_mysql']['login']; +$content['mysql_password1'] = $GLOBALS['install_mysql']['password1']; +$content['mysql_password2'] = $GLOBALS['install_mysql']['password2']; // Set constants for SMTP data -$content['smtp_host'] = $smtpHost; -$content['smtp_user'] = $smtpUser; -$content['smtp_pass1'] = $smtpPass1; -$content['smtp_pass2'] = $smtpPass2; +$content['smtp_host'] = $smtpHost; +$content['smtp_user'] = $smtpUser; +$content['smtp_password1'] = $smtpPass1; +$content['smtp_password2'] = $smtpPass2; // Load template addTemplateToInstallContent('install_page3', $content); diff --git a/inc/install/install_page_5.php b/inc/install/install_page_5.php index d3aa53bc7b..d1fdb7bc2d 100644 --- a/inc/install/install_page_5.php +++ b/inc/install/install_page_5.php @@ -48,9 +48,9 @@ $content['slogan'] = postRequestElement('slogan'); $content['email'] = postRequestElement('email'); // SMTP settings -$content['smtp_host'] = postRequestElement('smtp_host'); -$content['smtp_user'] = postRequestElement('smtp_user'); -$content['smtp_pass'] = postRequestElement('smtp_pass1'); +$content['smtp_host'] = postRequestElement('smtp_host'); +$content['smtp_user'] = postRequestElement('smtp_user'); +$content['smtp_password'] = postRequestElement('smtp_password1'); // Database login data $OUT = ''; diff --git a/inc/install/install_page_finalize.php b/inc/install/install_page_finalize.php index 6cd0f3032f..572dcd2a9a 100644 --- a/inc/install/install_page_finalize.php +++ b/inc/install/install_page_finalize.php @@ -49,7 +49,7 @@ if ((isPostRequestElementSet('finalize')) && (!isInstalled())) { unset($GLOBALS['is_sql_link_up']); // Connect to database server - SQL_CONNECT($GLOBALS['install_mysql']['host'], $GLOBALS['install_mysql']['login'], $GLOBALS['install_mysql']['pass1'], __FILE__, __LINE__); + SQL_CONNECT($GLOBALS['install_mysql']['host'], $GLOBALS['install_mysql']['login'], $GLOBALS['install_mysql']['password1'], __FILE__, __LINE__); // Is the link up? if (SQL_IS_LINK_UP()) { @@ -102,15 +102,15 @@ if ((isPostRequestElementSet('finalize')) && (!isInstalled())) { foreach ($GLOBALS['install_mysql'] as $key => $value) { $OUT .= ' '; } // END foreach - $content['mysql_hidden'] = $OUT; - $content['spath'] = postRequestElement('spath'); - $content['burl'] = postRequestElement('burl'); - $content['title'] = postRequestElement('title'); - $content['slogan'] = postRequestElement('slogan'); - $content['email'] = postRequestElement('email'); - $content['smtp_host'] = postRequestElement('smtp_host'); - $content['smtp_user'] = postRequestElement('smtp_user'); - $content['smtp_pass'] = postRequestElement('smtp_pass1'); + $content['mysql_hidden'] = $OUT; + $content['spath'] = postRequestElement('spath'); + $content['burl'] = postRequestElement('burl'); + $content['title'] = postRequestElement('title'); + $content['slogan'] = postRequestElement('slogan'); + $content['email'] = postRequestElement('email'); + $content['smtp_host'] = postRequestElement('smtp_host'); + $content['smtp_user'] = postRequestElement('smtp_user'); + $content['smtp_password'] = postRequestElement('smtp_password1'); // Load template addTemplateToInstallContent('install_fatal_errors', $content); @@ -131,12 +131,12 @@ if ((isPostRequestElementSet('finalize')) && (!isInstalled())) { postRequestElement('mysql', 'host'), postRequestElement('mysql', 'dbase'), postRequestElement('mysql', 'login'), - postRequestElement('mysql', 'pass1'), + postRequestElement('mysql', 'password1'), postRequestElement('mysql', 'prefix'), postRequestElement('mysql', 'type'), postRequestElement('smtp_host'), postRequestElement('smtp_user'), - postRequestElement('smtp_pass1') + postRequestElement('smtp_password1') ); // Register ext-sql_patches and ext-task diff --git a/inc/language/install_de.php b/inc/language/install_de.php index 68aee539cf..4b191124f0 100644 --- a/inc/language/install_de.php +++ b/inc/language/install_de.php @@ -57,6 +57,7 @@ addMessages(array( 'INSTALLER_FIN_SECU' => "Sie sollten jetzt die Dateien install.php und inc/install-inc.php von Ihrem Server löschen. Dies ist zwar normalerweise nicht erforderlich, Sie sollten es aber dennoch tun, um die Sicherheit zusätzlich zu erhöhen.", 'INSTALLER_CONTINUE_ADMIN' => "Weiter zum Administrationsbereich...", 'INSTALLER_INIT_PLEASE_WAIT' => "Einen Augenblick, die Installation wird vorbereitet ...", + 'INSTALLER_MARK_EXTENSION' => "Erweiterung %s zur Installation markieren", // Plain installer - general 'INSTALLER_SQL_IMPORT_FAILED' => "Konnte die SQL-Dateien aus install/ nicht nachladen. Bitte Zugriffsrechte (CHMOD) auf die Dateien überprüfen. Diese sollten 644 mindestens aufweisen.", @@ -86,6 +87,7 @@ addMessages(array( 'INSTALLER_PAGE_DATABASE_CONFIG_TITLE' => "Zugangsdaten zur Datenbank", 'INSTALLER_PAGE_SMTP_CONFIG_TITLE' => "SMTP-Server Einstellungen", 'INSTALLER_PAGE_OTHER_CONFIG_TITLE' => "Verschiedene Einstellungen", + 'INSTALLER_PAGE_EXTENSIONS_TITLE' => "Erweiterungen installieren", 'INSTALLER_PAGE_OVERVIEW_TITLE' => "Die Installation kann beginnen", // Installation pages descriptions @@ -158,6 +160,8 @@ addMessages(array( 'INSTALLER_TAB_NAVIGATION_SMTP_CONFIG_LINK' => "SMTP-Daten", 'INSTALLER_TAB_NAVIGATION_OTHER_CONFIG_TITLE' => "Seite 5: Sonstige Grundeinstellungen", 'INSTALLER_TAB_NAVIGATION_OTHER_CONFIG_LINK' => "Sonstiges", + 'INSTALLER_TAB_NAVIGATION_EXTENSIONS_TITLE' => "Erweiterungen installieren", + 'INSTALLER_TAB_NAVIGATION_EXTENSIONS_LINK' => "Erweiterungen", 'INSTALLER_TAB_NAVIGATION_OVERVIEW_TITLE' => "Installationszusammenfassung", 'INSTALLER_TAB_NAVIGATION_OVERVIEW_LINK' => "Zusammenfassung", @@ -189,6 +193,9 @@ addMessages(array( 'INSTALLER_CHANGED_ELEMENT_WRITE_FOOTER' => "Sie haben die Einstellung für das Ausgeben der Fusszeile geändert.", 'INSTALLER_CHANGED_ELEMENT_ENABLE_BACKLINK' => "Sie haben die Einstellung für den Backlink zu {?SERVER_URL?} geändert.", + // Changed elements - extensions + 'INSTALLER_CHANGED_ELEMENT_EXTENSION' => "Die Erweiterung %s wurde aus- oder abgewählt.", + // Fieldset legends 'INSTALLER_BASE_DATA_LEGEND_BASE_URL_PATH' => "Basis-Pfad und -URL:", 'INSTALLER_BASE_DATA_LEGEND_TITLE_SLOGAN' => "{?mt_word?}-Titel und Werbespruch:", @@ -252,6 +259,9 @@ addMessages(array( 'INSTALLER_FIELD_FAILED_WARN_NO_PASS' => "Es wurde weder Y noch N für 'WARN_NO_PASS' übergeben.", 'INSTALLER_FIELD_FAILED_WRITE_FOOTER' => "Es wurde weder Y noch N für 'WRITE_FOOTER' übergeben.", 'INSTALLER_FIELD_FAILED_ENABLE_BACKLINK' => "Es wurde weder Y noch N für 'ENABLE_BACKLINK' übergeben.", + + // Other notices + 'INSTALLER_EXTENSIONS_NOTICE' => "Sie wollten mindestens ext-sql_patches und zur besseren Übersicht im Adminbereich ext-task installieren. Sie können nach der Installation jederzeit weitere Erweiterungen hinzuinstallieren und brauchen dazu nicht das gesamte Script neu aufsetzen.", )); // [EOF] diff --git a/inc/libs/admins_functions.php b/inc/libs/admins_functions.php index beac76adc4..1e85afc090 100644 --- a/inc/libs/admins_functions.php +++ b/inc/libs/admins_functions.php @@ -194,17 +194,17 @@ function adminsChangeAdminAccount ($postData, $element = '', $displayMessage = T // Admin account saved $message = '{--ADMIN_ACCOUNT_SAVED--}'; - } elseif ((!empty($postData['pass1'])) && (!empty($postData['pass2']))) { + } elseif ((!empty($postData['password1'])) && (!empty($postData['password2']))) { // Update only if both passwords match - if (($postData['pass1'][$id] == $postData['pass2'][$id])) { + if (($postData['password1'][$id] == $postData['password2'][$id])) { // Save only when both passwords are the same (also when they are empty) $add = ''; $cache_update = 1; // Generate hash - $hash = generateHash($postData['pass1'][$id]); + $hash = generateHash($postData['password1'][$id]); // Save password when set - if (!empty($postData['pass1'][$id])) { + if (!empty($postData['password1'][$id])) { $add = sprintf(",`password`='%s'", SQL_ESCAPE($hash)); } // END - if @@ -225,7 +225,7 @@ function adminsChangeAdminAccount ($postData, $element = '', $displayMessage = T if (!empty($add)) { setAdminMd5($hash); } // END - if - } elseif (generateHash($postData['pass1'][$id], $salt) != getAdminMd5()) { + } elseif (generateHash($postData['password1'][$id], $salt) != getAdminMd5()) { // Update password cookie setAdminMd5($hash); } diff --git a/inc/libs/register_functions.php b/inc/libs/register_functions.php index 0b8f952157..703a2a0759 100644 --- a/inc/libs/register_functions.php +++ b/inc/libs/register_functions.php @@ -187,19 +187,19 @@ function isRegistrationDataComplete () { setPostRequestArray($postArray); // Are both passwords zero length? - if ((strlen(postRequestElement('pass1')) == 0) && (strlen(postRequestElement('pass2')) == 0) && ($isOkay === TRUE)) { + if ((strlen(postRequestElement('password1')) == 0) && (strlen(postRequestElement('password2')) == 0) && ($isOkay === TRUE)) { // Is the extension 'register' newer or equal 0.5.5? if ((isExtensionInstalledAndNewer('register', '0.5.5')) && (isRegisterGeneratePasswordEmptyEnabled())) { // Generate a random password $randomPassword = generatePassword(); // Set it in both entries - setPostRequestElement('pass1', $randomPassword); - setPostRequestElement('pass2', $randomPassword); + setPostRequestElement('password1', $randomPassword); + setPostRequestElement('password2', $randomPassword); } else { // Not allowed or no recent extension version - setPostRequestElement('pass1', '!'); - setPostRequestElement('pass2', '!'); + setPostRequestElement('password1', '!'); + setPostRequestElement('password2', '!'); // ... which is both not okay //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Random password generation not possible, isExtensionInstalledAndNewer(register, 0.5.5)=' . intval(isExtensionInstalledAndNewer('register', '0.5.5')) . ',isRegisterGeneratePasswordEmptyEnabled()=' . intval(isRegisterGeneratePasswordEmptyEnabled())); @@ -208,35 +208,35 @@ function isRegistrationDataComplete () { } // END - if // Did he enter his password twice? - if (((!isPostRequestElementSet('pass1')) || (!isPostRequestElementSet('pass2'))) || ((postRequestElement('pass1') != postRequestElement('pass2')) && (isPostRequestElementSet('pass1')) && (isPostRequestElementSet('pass2')))) { - if ((postRequestElement('pass1') != postRequestElement('pass2')) && (isPostRequestElementSet('pass1')) && (isPostRequestElementSet('pass2'))) { + if (((!isPostRequestElementSet('password1')) || (!isPostRequestElementSet('password2'))) || ((postRequestElement('password1') != postRequestElement('password2')) && (isPostRequestElementSet('password1')) && (isPostRequestElementSet('password2')))) { + if ((postRequestElement('password1') != postRequestElement('password2')) && (isPostRequestElementSet('password1')) && (isPostRequestElementSet('password2'))) { // Both passwords did not match - setPostRequestElement('pass1', '!'); - setPostRequestElement('pass2', '!'); + setPostRequestElement('password1', '!'); + setPostRequestElement('password2', '!'); //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'User did not enter same passwords.'); } else { - if (!isPostRequestElementSet('pass1')) { + if (!isPostRequestElementSet('password1')) { // Password 1 is empty - setPostRequestElement('pass1', '!'); - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'User did not enter pass1.'); + setPostRequestElement('password1', '!'); + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'User did not enter password1.'); } else { // Password 2 is empty - setPostRequestElement('pass1', ''); + setPostRequestElement('password1', ''); } - if (!isPostRequestElementSet('pass2')) { + if (!isPostRequestElementSet('password2')) { // Password 2 is empty - setPostRequestElement('pass2', '!'); - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'User did not enter pass2.'); + setPostRequestElement('password2', '!'); + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'User did not enter password2.'); } else { // Password 1 is empty - setPostRequestElement('pass2', ''); + setPostRequestElement('password2', ''); } } $isOkay = FALSE; } // END - if // Is the password long enouth? - if ((strlen(postRequestElement('pass1')) < getPassLen()) && ($isOkay === TRUE)) { + if ((strlen(postRequestElement('password1')) < getPassLen()) && ($isOkay === TRUE)) { $GLOBALS['registration_short_password'] = TRUE; //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'User did enter a short password.'); $isOkay = FALSE; @@ -372,7 +372,7 @@ function doUserRegistration () { bigintval(postRequestElement('day')), bigintval(postRequestElement('month')), bigintval(postRequestElement('year')), - generateHash(postRequestElement('pass1')), + generateHash(postRequestElement('password1')), bigintval(postRequestElement('max_mails')), bigintval(postRequestElement('max_mails')), convertZeroToNull(postRequestElement('refid')), @@ -457,7 +457,7 @@ function doUserRegistration () { 'zip' => bigintval(postRequestElement('zip')), 'country' => $GLOBALS['register_country_data'], 'refid' => SQL_ESCAPE(postRequestElement('refid')), - 'password' => SQL_ESCAPE(postRequestElement('pass1')), + 'password' => SQL_ESCAPE(postRequestElement('password1')), ); } else { // No ZIP code entered @@ -473,7 +473,7 @@ function doUserRegistration () { 'zip' => '', 'country' => $GLOBALS['register_country_data'], 'refid' => SQL_ESCAPE(postRequestElement('refid')), - 'password' => SQL_ESCAPE(postRequestElement('pass1')), + 'password' => SQL_ESCAPE(postRequestElement('password1')), ); } diff --git a/inc/libs/security_functions.php b/inc/libs/security_functions.php index e73036ca9b..10002eea71 100644 --- a/inc/libs/security_functions.php +++ b/inc/libs/security_functions.php @@ -181,7 +181,7 @@ if (!isset($_POST)) { // Generate arrays which holds the relevante chars to replace $GLOBALS['security_chars'] = array( // The chars we are looking for... - 'from' => array('/', '.', chr(39), '$', '(', ')', '{--', '--}', '{?', '?}', '%', ';', '[', ']', ':', '--', chr(92), chr(39)), + 'from' => array('/', '.', chr(39), '$', '(', ')', '{--', '--}', '{?', '?}', '%', ';', '[', ']', ':', '--', chr(92), chr(39), '<', '>'), // ... and we will replace to. 'to' => array( '{SLASH}', @@ -201,7 +201,9 @@ $GLOBALS['security_chars'] = array( '{DBL_DOT}', '{COMMENT}', '{BACKSLASH}', - '{SQUOTE}' + '{SQUOTE}', + '{OPEN_TAG}', + '{CLOSE_TAG}' ), ); diff --git a/inc/libs/sponsor_functions.php b/inc/libs/sponsor_functions.php index b60e222682..36bb1a990b 100644 --- a/inc/libs/sponsor_functions.php +++ b/inc/libs/sponsor_functions.php @@ -92,11 +92,11 @@ function handleSponsorRequest ($postData, $update=false, $messageArray = array() } break; - case 'pass1': + case 'password1': $k = ''; $v = ''; break; - case 'pass2': + case 'password2': $k = 'password'; $v = md5($v); break; @@ -390,17 +390,17 @@ function saveSponsorData ($postData, $content) { // Unsecure data which we don't want $UNSAFE = array('password', 'id', 'remote_addr', 'sponsor_created', 'last_online', 'status', 'ref_count', 'points_amount', 'points_used', 'refid', 'hash', 'last_payment', 'last_currency', - 'pass_old', 'ok', 'pass1', 'pass2'); + 'pass_old', 'ok', 'password1', 'password2'); // Set default message ("not saved") $message = '{--SPONSOR_ACCOUNT_DATA_NOT_SAVED--}'; // Check for submitted passwords - if ((!empty($postData['pass1'])) && (!empty($postData['pass2']))) { + if ((!empty($postData['password1'])) && (!empty($postData['password2']))) { // Are both passwords the same? - if ($postData['pass1'] == $postData['pass2']) { - // Okay, then set password and remove pass1 and pass2 - $postData['password'] = md5($postData['pass1']); + if ($postData['password1'] == $postData['password2']) { + // Okay, then set password and remove password1 and password2 + $postData['password'] = md5($postData['password1']); } // END - if } // END - if @@ -584,7 +584,7 @@ function doProcessSponsorFormRequest ($messageArray = array()) { $content['surname'] = postRequestElement('surname'); $content['family'] = postRequestElement('family'); $content['timestamp'] = generateDateTime(time(), 0); - $content['password'] = postRequestElement('pass1'); + $content['password'] = postRequestElement('password1'); // Generate email and send it to the new sponsor $message = loadEmailTemplate('sponsor_confirm', $content, $id); diff --git a/inc/module-functions.php b/inc/module-functions.php index 9fdd7d36ff..fd44d136dc 100644 --- a/inc/module-functions.php +++ b/inc/module-functions.php @@ -388,9 +388,9 @@ function ifModuleHasMenu ($module, $forceDb = FALSE) { } elseif (!isExtensionInstalled('sql_patches')) { // No ext-sql_patches installed, so maybe in admin/guest/member/sponsor area or no admin registered? $ret = in_array($module, array('admin', 'index', 'login', 'sponsor')); // Then there is a menu! - } else { - // Unsupported state! - logDebugMessage(__FUNCTION__, __LINE__, 'This should never be reached.'); + } elseif (!isInstallationPhase()) { + // Unsupported state, but ignored in installation phase + logDebugMessage(__FUNCTION__, __LINE__, 'This should never be reached, module[' . gettype($module) . ']=' . $module . ',forceDb=' . intval($forceDb)); } // Return status diff --git a/inc/modules/admin.php b/inc/modules/admin.php index 080748f72a..b67226cf91 100644 --- a/inc/modules/admin.php +++ b/inc/modules/admin.php @@ -79,11 +79,11 @@ if (!isAdminRegistered()) { // Cannot validate the login data and hash displayMessage('{--ADMIN_VALIDATION_RESET_LOGIN_HASH_FAILED--}'); } - } elseif ((isPostRequestElementSet('reset_pass')) && (isPostRequestElementSet('hash')) && (isPostRequestElementSet('admin_login')) && (isPostRequestElementSet('admin_pass1')) && (postRequestElement('admin_pass1') == postRequestElement('admin_pass2'))) { + } elseif ((isPostRequestElementSet('reset_pass')) && (isPostRequestElementSet('hash')) && (isPostRequestElementSet('admin_login')) && (isPostRequestElementSet('admin_password1')) && (postRequestElement('admin_password1') == postRequestElement('admin_password2'))) { // Okay, we shall the admin password here. So first revalidate the hash if (adminResetValidateHashLogin(postRequestElement('hash'), postRequestElement('admin_login'))) { // Output result - loadTemplate('admin_reset_password_done', FALSE, doResetAdminPassword(postRequestElement('admin_login'), postRequestElement('admin_pass1'))); + loadTemplate('admin_reset_password_done', FALSE, doResetAdminPassword(postRequestElement('admin_login'), postRequestElement('admin_password1'))); } else { // Validation failed displayMessage('{--ADMIN_VALIDATION_RESET_LOGIN_HASH_FAILED2--}'); diff --git a/inc/modules/admin/admin-inc.php b/inc/modules/admin/admin-inc.php index 67e1376547..c9f941dbd5 100644 --- a/inc/modules/admin/admin-inc.php +++ b/inc/modules/admin/admin-inc.php @@ -1594,16 +1594,18 @@ function registerFirstAdmin () { assert(!isAdminRegistered()); // Admin is not registered so we have to inform the user - if ((isFormSent('add_first_admin')) && ((!isPostRequestElementSet('admin_login')) || (!isPostRequestElementSet('admin_pass1')) || (strlen(postRequestElement('admin_pass1')) < getConfig('minium_admin_pass_length')) || (!isPostRequestElementSet('admin_pass2')) || (strlen(postRequestElement('admin_pass2')) < getConfig('minium_admin_pass_length')) || (postRequestElement('admin_pass1') != postRequestElement('admin_pass2')))) { + if ((isFormSent('add_first_admin')) && ((!isPostRequestElementSet('admin_login')) || (!isPostRequestElementSet('admin_password1')) || (strlen(postRequestElement('admin_password1')) < getConfig('minium_admin_pass_length')) || (!isPostRequestElementSet('admin_password2')) || (strlen(postRequestElement('admin_password2')) < getConfig('minium_admin_pass_length')) || (postRequestElement('admin_password1') != postRequestElement('admin_password2')))) { setPostRequestElement('add_first_admin', '***'); } // END - if // Clear error message $errorMessage = ''; + $ret = 'init'; + // Is form for first admin sent? if ((isFormSent('add_first_admin')) && (postRequestElement('add_first_admin') != '***')) { // Hash the password with the old function because we are here in install mode - $hashedPass = md5(postRequestElement('admin_pass1')); + $hashedPass = md5(postRequestElement('admin_password1')); // Kill maybe existing session variables destroyAdminSession(); @@ -1665,16 +1667,16 @@ function registerFirstAdmin () { // Init array elements $content['login_message'] = ''; - $content['pass1_message'] = ''; - $content['pass2_message'] = ''; + $content['password1_message'] = ''; + $content['password2_message'] = ''; $content['error_message'] = ''; // Yet-another notice-fix if ((isFormSent('add_first_admin')) && (postRequestElement('add_first_admin') == '***')) { // Init variables $loginMessage = ''; - $pass1Message = ''; - $pass2Message = ''; + $password1Message = ''; + $password2Message = ''; // No login entered? if (empty($content['admin_login'])) { @@ -1687,30 +1689,30 @@ function registerFirstAdmin () { } // END - if // No password 1 entered or to short? - if (!isPostRequestElementSet('admin_pass1')) { - $pass1Message = '{--ADMIN_NO_PASSWORD1--}'; - } elseif (strlen(postRequestElement('admin_pass1')) < getConfig('minium_admin_pass_length')) { - $pass1Message = '{--ADMIN_SHORT_PASSWORD1--}'; + if (!isPostRequestElementSet('admin_password1')) { + $password1Message = '{--ADMIN_NO_PASSWORD1--}'; + } elseif (strlen(postRequestElement('admin_password1')) < getConfig('minium_admin_pass_length')) { + $password1Message = '{--ADMIN_SHORT_PASSWORD1--}'; } // No password 2 entered or to short? - if (!isPostRequestElementSet('admin_pass2')) { - $pass2Message = '{--ADMIN_NO_PASSWORD2--}'; - } elseif (strlen(postRequestElement('admin_pass2')) < getConfig('minium_admin_pass_length')) { - $pass2Message = '{--ADMIN_SHORT_PASSWORD2--}'; + if (!isPostRequestElementSet('admin_password2')) { + $password2Message = '{--ADMIN_NO_PASSWORD2--}'; + } elseif (strlen(postRequestElement('admin_password2')) < getConfig('minium_admin_pass_length')) { + $password2Message = '{--ADMIN_SHORT_PASSWORD2--}'; } // Both didn't match? - if (postRequestElement('admin_pass1') != postRequestElement('admin_pass2')) { + if (postRequestElement('admin_password1') != postRequestElement('admin_password2')) { // No match - if (empty($pass1Message)) $pass1Message = '{--ADMIN_PASSWORD1_MISMATCH--}'; - if (empty($pass2Message)) $pass2Message = '{--ADMIN_PASSWORD2_MISMATCH--}'; + if (empty($password1Message)) $password1Message = '{--ADMIN_PASSWORD1_MISMATCH--}'; + if (empty($password2Message)) $password2Message = '{--ADMIN_PASSWORD2_MISMATCH--}'; } // END - if // Output error messages $content['login_message'] = loadTemplate('admin_login_msg', TRUE, $loginMessage); - $content['pass1_message'] = loadTemplate('admin_login_msg', TRUE, $pass1Message); - $content['pass2_message'] = loadTemplate('admin_login_msg', TRUE, $pass2Message); + $content['password1_message'] = loadTemplate('admin_login_msg', TRUE, $password1Message); + $content['password2_message'] = loadTemplate('admin_login_msg', TRUE, $password2Message); $content['error_message'] = loadTemplate('admin_login_msg', TRUE, $errorMessage); } // END - if diff --git a/inc/modules/admin/what-admins_add.php b/inc/modules/admin/what-admins_add.php index eb146645f2..0b5d3932fb 100644 --- a/inc/modules/admin/what-admins_add.php +++ b/inc/modules/admin/what-admins_add.php @@ -49,9 +49,9 @@ $FORM = TRUE; // Is the form sent? if (isFormSent('add')) { // Check all - if ((isPostRequestElementSet('login')) && (isPostRequestElementSet('email')) && (isPostRequestElementSet('pass1')) && (isPostRequestElementSet('pass2')) && (postRequestElement('pass1') == postRequestElement('pass2'))) { + if ((isPostRequestElementSet('login')) && (isPostRequestElementSet('email')) && (isPostRequestElementSet('password1')) && (isPostRequestElementSet('password2')) && (postRequestElement('password1') == postRequestElement('password2'))) { // Add admin when not added already - if (addAdminAccount(postRequestElement('login'), generateHash(postRequestElement('pass1')), postRequestElement('email')) == 'done') { + if (addAdminAccount(postRequestElement('login'), generateHash(postRequestElement('password1')), postRequestElement('email')) == 'done') { // Do not ouput any form! $FORM = FALSE; diff --git a/inc/modules/admin/what-edit_sponsor.php b/inc/modules/admin/what-edit_sponsor.php index cf61c57c58..c377966e43 100644 --- a/inc/modules/admin/what-edit_sponsor.php +++ b/inc/modules/admin/what-edit_sponsor.php @@ -120,10 +120,10 @@ LIMIT 1", case 'edit': // Edit sponsor account $PASS = TRUE; - if ((postRequestElement('pass1') != postRequestElement('pass2')) || ((!isPostRequestElementSet('pass1')) && (!isPostRequestElementSet('pass1')))) { + if ((postRequestElement('password1') != postRequestElement('password2')) || ((!isPostRequestElementSet('password1')) && (!isPostRequestElementSet('password1')))) { // Remove passwords - unsetPostRequestElement('pass1'); - unsetPostRequestElement('pass2'); + unsetPostRequestElement('password1'); + unsetPostRequestElement('password2'); $PASS = FALSE; } // END - if @@ -137,7 +137,7 @@ LIMIT 1", postRequestElement('gender' , '{%pipe,translateGender=' . postRequestElement('gender') . '%}'); postRequestElement('warning_interval', '{%pipe,createFancyTime=' . postRequestElement('warning_interval') . '%}'); - if ($PASS === FALSE) setPostRequestElement('pass1', '{--SPONSOR_PASS_UNCHANGED--}'); + if ($PASS === FALSE) setPostRequestElement('password1', '{--SPONSOR_PASS_UNCHANGED--}'); // Load email template and send the mail away $message = loadEmailTemplate('admin_sponsor_edit', postRequestArray(), FALSE); diff --git a/inc/modules/admin/what-edit_user.php b/inc/modules/admin/what-edit_user.php index a241477977..05602f4958 100644 --- a/inc/modules/admin/what-edit_user.php +++ b/inc/modules/admin/what-edit_user.php @@ -72,13 +72,13 @@ if ((!isGetRequestElementSet('userid')) || (SQL_NUMROWS($result_main) == 1)) { } elseif (isFormSent('edit')) { // Ok, change the account... $updateUser = FALSE; $add = ''; - if ((!isPostRequestElementSet('pass1')) && (!isPostRequestElementSet('pass2'))) { + if ((!isPostRequestElementSet('password1')) && (!isPostRequestElementSet('password2'))) { // Don't change the password $updateUser = TRUE; - } elseif ((postRequestElement('pass1') == postRequestElement('pass2'))) { + } elseif ((postRequestElement('password1') == postRequestElement('password2'))) { // Change the password $updateUser = TRUE; - $add = ",`password`='" . generateHash(postRequestElement('pass1')) . "'"; + $add = ",`password`='" . generateHash(postRequestElement('password1')) . "'"; } if ($updateUser === TRUE) { diff --git a/inc/modules/guest/what-extensions.php b/inc/modules/guest/what-extensions.php index 2023adb92c..57bf8b9b5c 100644 --- a/inc/modules/guest/what-extensions.php +++ b/inc/modules/guest/what-extensions.php @@ -44,16 +44,7 @@ if (!defined('__SECURITY')) { addYouAreHereLink('guest', __FILE__); // Get all extension files -$extensions = getArrayFromDirectory( - 'templates/' . getLanguage() . '/html/ext/', - 'ext_', - false, - false, - array(), - '.tpl', - '@(\.|\.\.)$@', - false -); +$extensions = loadAllExtensionsByTemplate(); // Now iterate through all and load that template file $OUT = ''; diff --git a/inc/modules/guest/what-register.php b/inc/modules/guest/what-register.php index 96b3265873..2036b9f7e1 100644 --- a/inc/modules/guest/what-register.php +++ b/inc/modules/guest/what-register.php @@ -84,11 +84,11 @@ if ((isFormSent()) && (isRegistrationDataComplete())) { setPostRequestElement('family', ''); } // END - if - if ((postRequestElement('pass1') == '!') && (postRequestElement('pass2') == '!')) { + if ((postRequestElement('password1') == '!') && (postRequestElement('password2') == '!')) { registerOutputFailedMessage('ENTER_BOTH_PASSWORDS'); - } elseif (postRequestElement('pass1') == '!') { + } elseif (postRequestElement('password1') == '!') { registerOutputFailedMessage('ENTER_PASSWORD1'); - } elseif (postRequestElement('pass2') == '!') { + } elseif (postRequestElement('password2') == '!') { registerOutputFailedMessage('ENTER_PASSWORD2'); } diff --git a/inc/modules/guest/what-sponsor_reg.php b/inc/modules/guest/what-sponsor_reg.php index 80fee158f5..8a19eb5607 100644 --- a/inc/modules/guest/what-sponsor_reg.php +++ b/inc/modules/guest/what-sponsor_reg.php @@ -167,22 +167,22 @@ if (isFormSent()) { } // END - if // Did he enter his password twice? - if (((!isPostRequestElementSet('pass1')) || (!isPostRequestElementSet('pass2'))) || ((postRequestElement('pass1') != postRequestElement('pass2')) && (isPostRequestElementSet('pass1')) && (isPostRequestElementSet('pass2')))) { - if ((postRequestElement('pass1') != postRequestElement('pass2')) && (isPostRequestElementSet('pass1')) && (isPostRequestElementSet('pass2'))) { + if (((!isPostRequestElementSet('password1')) || (!isPostRequestElementSet('password2'))) || ((postRequestElement('password1') != postRequestElement('password2')) && (isPostRequestElementSet('password1')) && (isPostRequestElementSet('password2')))) { + if ((postRequestElement('password1') != postRequestElement('password2')) && (isPostRequestElementSet('password1')) && (isPostRequestElementSet('password2'))) { // Passwords missmatch array_push($formErrors, '{--SPONSOR_PASSWORDS_MISMATCH--}'); } else { - if (!isPostRequestElementSet('pass1')) { + if (!isPostRequestElementSet('password1')) { // Password 1 is empty array_push($formErrors, '{--SPONSOR_PASSWORD1_EMPTY--}'); } - if (!isPostRequestElementSet('pass2')) { + if (!isPostRequestElementSet('password2')) { // Password 2 is empty array_push($formErrors, '{--SPONSOR_PASSWORD2_EMPTY--}'); } } - } elseif (strlen(postRequestElement('pass1')) < getPassLen()) { + } elseif (strlen(postRequestElement('password1')) < getPassLen()) { // Password is to short! array_push($formErrors, '{--SPONSOR_PASSWORD_TOO_SHORT--}'); } diff --git a/inc/modules/member/what-mydata.php b/inc/modules/member/what-mydata.php index 168fcacc7f..e8a69633e3 100644 --- a/inc/modules/member/what-mydata.php +++ b/inc/modules/member/what-mydata.php @@ -231,8 +231,8 @@ LIMIT 1", displayMessage('{--MEMBER_EMAIL_IS_ALREADY_REGISTERED--}'); } else { // Generate hash - $hash = generateHash(postRequestElement('pass1'), substr($content['password'], 0, -40)); - if ((($hash == $content['password']) || (postRequestElement('pass1') == postRequestElement('pass2'))) && (isPostRequestElementSet('pass1'))) { + $hash = generateHash(postRequestElement('password1'), substr($content['password'], 0, -40)); + if ((($hash == $content['password']) || (postRequestElement('password1') == postRequestElement('password2'))) && (isPostRequestElementSet('password1'))) { // Only on simple changes normal mode is active = no email or password changed $mode = 'normal'; $AND = ''; diff --git a/inc/modules/sponsor/account.php b/inc/modules/sponsor/account.php index 9be23f33a8..167c65eeb1 100644 --- a/inc/modules/sponsor/account.php +++ b/inc/modules/sponsor/account.php @@ -78,16 +78,16 @@ if (SQL_NUMROWS($result) == 1) { } elseif (md5(postRequestElement('pass_old')) != getSession('sponsorpass')) { // Entered password didn't match password in DB $message = '{--SPONSOR_CURRENT_PASSWORD_DIDNOT_MATCH_DB--}'; - } elseif ((isPostRequestElementSet('pass1')) && (isPostRequestElementSet('pass2')) && (postRequestElement('pass1') != postRequestElement('pass2'))) { + } elseif ((isPostRequestElementSet('password1')) && (isPostRequestElementSet('password2')) && (postRequestElement('password1') != postRequestElement('password2'))) { // Both new passwords did not match $message = '{--SPONSOR_BOTH_NEW_PASSWORDS_DIDNOT_MATCH--}'; - } elseif ((!isPostRequestElementSet('pass1')) && (isPostRequestElementSet('pass2'))) { + } elseif ((!isPostRequestElementSet('password1')) && (isPostRequestElementSet('password2'))) { // No password one entered $message = '{--SPONSOR_PASSWORD_ONE_EMPTY--}'; - } elseif ((isPostRequestElementSet('pass1')) && (!isPostRequestElementSet('pass2'))) { + } elseif ((isPostRequestElementSet('password1')) && (!isPostRequestElementSet('password2'))) { // No password two entered $message = '{--SPONSOR_PASSWORD_TWO_EMPTY--}'; - } elseif ((isPostRequestElementSet('pass1')) && (strlen(postRequestElement('pass1')) < getPassLen())) { + } elseif ((isPostRequestElementSet('password1')) && (strlen(postRequestElement('password1')) < getPassLen())) { // Too short password $message = '{--SPONSOR_PASSWORD_TOO_SHORT--}'; } else { @@ -95,10 +95,10 @@ if (SQL_NUMROWS($result) == 1) { $PASS_AND = ''; $PASS_DATA = ''; // Check if the sponsor wants to change his/her password - if ((postRequestElement('pass1') == postRequestElement('pass2')) && (isPostRequestElementSet('pass1')) && (postRequestElement('pass1') != postRequestElement('pass_old'))) { + if ((postRequestElement('password1') == postRequestElement('password2')) && (isPostRequestElementSet('password1')) && (postRequestElement('password1') != postRequestElement('pass_old'))) { // Change current password $PASS_AND = ",`password`='%s'"; - $PASS_DATA = md5(postRequestElement('pass1')); + $PASS_DATA = md5(postRequestElement('password1')); } // END - if // Unsecure data which we don't want here diff --git a/inc/template-functions.php b/inc/template-functions.php index 00d4b9d9a5..f53fc9115a 100644 --- a/inc/template-functions.php +++ b/inc/template-functions.php @@ -344,6 +344,10 @@ function loadTemplate ($template, $return = FALSE, $content = array(), $compileC // JavaScripts don't like entities, dollar signs and timings //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Reached!'); $GLOBALS['template_eval']['html'][$template] = '$ret = decodeEntities("' . compileRawCode(escapeJavaScriptQuotes($GLOBALS['template_content']['html'][$template]), FALSE, TRUE, TRUE, $compileCode) . '");'; + } elseif (isAjaxOutputMode()) { + // AJAX (JSON content) + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Reached!'); + $GLOBALS['template_eval']['html'][$template] = '$ret = "' . compileRawCode(escapeJavaScriptQuotes($GLOBALS['template_content']['html'][$template]), FALSE, TRUE, TRUE, $compileCode) . '";'; } else { // Prepare eval() command, other output doesn't like entities, maybe //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Reached!'); @@ -354,6 +358,10 @@ function loadTemplate ($template, $return = FALSE, $content = array(), $compileC $ret = '' . $GLOBALS['template_content']['html'][$template] . ''; //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Reached!'); $GLOBALS['template_eval']['html'][$template] = '$ret = "' . getColorSwitchCode($template) . compileRawCode(escapeQuotes($ret), FALSE, TRUE, TRUE, $compileCode) . '";'; + } elseif (isAjaxOutputMode()) { + // AJAX (JSON content) + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Reached!'); + $GLOBALS['template_eval']['html'][$template] = '$ret = "' . compileRawCode(escapeJavaScriptQuotes($GLOBALS['template_content']['html'][$template]), FALSE, TRUE, TRUE, $compileCode) . '";'; } else { // JavaScript again //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Reached!'); @@ -506,6 +514,7 @@ function loadEmailTemplate ($template, $content = array(), $userid = NULL, $load $GLOBALS['template_content']['email'][$template] = readFromFile($FQFN); // Run code + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Reached!'); $GLOBALS['template_eval']['email'][$template] = '$newContent = decodeEntities("' . compileRawCode(escapeQuotes($GLOBALS['template_content']['email'][$template])) . '");'; } elseif (!empty($template)) { // Template file not found @@ -536,7 +545,7 @@ function loadEmailTemplate ($template, $content = array(), $userid = NULL, $load if ((isset($GLOBALS['template_eval']['email'][$template])) && ($GLOBALS['template_eval']['email'][$template] != '404')) { // Eval the code //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'template=' . $template . ' - BEFORE EVAL'); - ///* DEBUG: */ print('
'.htmlentities($GLOBALS['template_eval']['email'][$template]).'
'); + //* DEBUG: */ print('
'.htmlentities($GLOBALS['template_eval']['email'][$template]).'
'); eval($GLOBALS['template_eval']['email'][$template]); //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'template=' . $template . ' - AFTER EVAL'); } // END - if @@ -1693,7 +1702,7 @@ function sendModeMails ($mod, $modes) { $hash = encodeHashForCookie(getUserData('password')); // Does the hash match or should we change it? - if (($hash == getSession('u_hash')) || (postRequestElement('pass1') == postRequestElement('pass2'))) { + if (($hash == getSession('u_hash')) || (postRequestElement('password1') == postRequestElement('password2'))) { // Load the data $content = getUserDataArray(); diff --git a/inc/wrapper-functions.php b/inc/wrapper-functions.php index 4324ae39c9..fe5834dcd7 100644 --- a/inc/wrapper-functions.php +++ b/inc/wrapper-functions.php @@ -326,7 +326,7 @@ function isInstalling () { // Determine whether we are installing if (!isset($GLOBALS['__mailer_installing'])) { // Check URL (css.php/js.php need this) - $GLOBALS['__mailer_installing'] = isGetRequestElementSet('installing'); + $GLOBALS['__mailer_installing'] = (isGetRequestElementSet('installing') || ((isGetRequestElementSet('level')) && (getRequestElement('level') == 'install'))); } // END - if // Return result @@ -3354,5 +3354,23 @@ function encodeJson ($data) { return json_encode($data, JSON_FORCE_OBJECT); } +// Get all extension files +function loadAllExtensionsByTemplate () { + // Get all + $extensions = getArrayFromDirectory( + 'templates/' . getLanguage() . '/html/ext/', + 'ext_', + false, + false, + array(), + '.tpl', + '@(\.|\.\.)$@', + false + ); + + // Return them + return $extensions; +} + // [EOF] ?> diff --git a/js/ajax-common.js b/js/ajax-common.js index ccef02a08a..3686444aed 100644 --- a/js/ajax-common.js +++ b/js/ajax-common.js @@ -31,6 +31,7 @@ var currentTabId = null; var defaultTabId = null; var footerElements = new Array(); var changedElements = new Array(); +var data = new Array(); var formChanged = false; var saveChangesId = null; var lastErrorMessage = null; @@ -53,12 +54,15 @@ function isElementVisible (prefix, element) { var el = document.getElementById(prefix + '_' + element); // Is element set? - if (el == null || el == undefined) { + if ((el == null) || (el == undefined)) { throw new '"' + prefix + '_' + element + '" does not exist.'; + } else if ((el.style.display == undefined) || (el.style.display == '')) { + throw new '"' + prefix + '_' + element + '" has no style.display element.'; } // Default is visible - var isVisible = ((el.style.display == undefined) || ((el.style.display != 'none') && (el.style.display != ''))); + var isVisible = (el.style.display != 'none'); + //* DEBUG: */ alert(prefix + '_' + element + ':' + el.style.display + '=' + isVisible); // Return status return isVisible; @@ -66,8 +70,8 @@ function isElementVisible (prefix, element) { // Marks a tab navigation entry function markTabNavigation (prefix, tab) { - // Is process working? - if (isElementVisible(prefix, 'process')) { + // Is progress working? + if (isElementVisible(prefix, 'progress')) { // Then exit silently return; } // END - if @@ -121,11 +125,15 @@ function disableElement (element) { // Enables a given footer navigation element function enableFooterNavigationPage (element) { - // Remove the 'disabled' class and attribute + // Is it 'finish'? if (element == 'finish') { + // Then without '_page' suffix enableElement('input#finish'); } else { + // Regular element with '_page' suffix enableElement('input#' + element + '_page'); + + // Disable 'finish' element disableElement('input#finish'); } } @@ -134,22 +142,28 @@ function enableFooterNavigationPage (element) { function resetFooterNavigation () { // Remove the 'disabled' class and attribute for (var i = 0; i < footerElements.length; i++) { - $('input#' + footerElements[i] + '_page').addClass('disabled'); - $('input#' + footerElements[i] + '_page').attr('disabled', 'disabled'); - $('input#' + footerElements[i] + '_page').blur(); + disableElement('input#' + footerElements[i] + '_page'); } // END - for + + // Disable this element + disableElement('input#finish'); } // Getter for AJAX content function getAjaxContent () { // Is it defined? - if ($('body').data('ajax_content') == undefined) { + if (data['ajax_content'] == undefined) { // Not set throw new 'ajax_content requested but not set.'; } // END - if // Return it - return $('body').data('ajax_content'); + return data['ajax_content']; +} + +// Setter for AJAX content +function setAjaxContent (ajax_content) { + data['ajax_content'] = ajax_content; } // "Setter" for AJAX content but does decode the content @@ -161,24 +175,20 @@ function setAjaxDecodedContent (ajax_content) { setAjaxContent(decoded); } -// Setter for AJAX content -function setAjaxContent (ajax_content) { - $('body').data('ajax_content', ajax_content); -} - // Getter for AJAX success function getAjaxSuccess () { - return $('body').data('ajax_success'); + return data['ajax_success']; } // Setter for AJAX success function setAjaxSuccess (success) { - $('body').data('ajax_success', success); + data['ajax_success'] = success; } // Set AJAX reply and decode JSON if requested function setAjaxReply (reply, isJson) { // Is it JSON URL-encoded content? + //* DEBUG: */ alert('setAjaxReply(): reply=' + reply + ',isJson=' + isJson); if ((isJson != undefined) && (isJson == true)) { // Decode URL-encoding (for some reason it must be here ...) var localReply = decodeUrlEncoding(reply); @@ -209,6 +219,7 @@ function sendAjaxRequest (level, doValue, extra, isJson) { data: 'level=' + level + '&do=' + doValue + extra, dataType: 'json', async: false, + timeout: 10000, // Called on success success: function (ajax_content) { @@ -261,13 +272,14 @@ function sendAjaxRequest (level, doValue, extra, isJson) { }); // Return status + //* DEBUG: */ alert(getAjaxSuccess() + ':' + level + ',' + doValue + ',' + extra + ',' + isJson); return getAjaxSuccess(); } // Enables footer navigation buttons function enableFooterNavigation (prefix, tabId) { - // Is process working? - if (isElementVisible(prefix, 'process')) { + // Is progress working? + if (isElementVisible(prefix, 'progress')) { // Then exit silently return; } // END - if @@ -290,8 +302,8 @@ function enableFooterNavigation (prefix, tabId) { // Requests an AJAX content function requestAjaxContent (prefix, htmlId, tabId, footerNavigation) { - // Is process working? - if (isElementVisible(prefix, 'process')) { + // Is progress working? + if (isElementVisible(prefix, 'progress')) { // Then exit silently return; } // END - if @@ -351,14 +363,14 @@ function displayTestWindow (prefix, element) { // Register click-event for error window $('#' + prefix + '_error_close').click(function () { // Close the window - closeErrorWindow(prefix); + closeErrorWindow(prefix, true, false); }); // Register click-event for warning window $('#' + prefix + '_warning_close').click(function () { // Close the window //* DEBUG: */ alert('displayTestWindow(): prefix=' + prefix + ' - calling closeWarningWindow()'); - closeWarningWindow(prefix); + closeWarningWindow(prefix, true, false); }); // Request it from the AJAX backend @@ -381,13 +393,13 @@ function displayTestWindow (prefix, element) { function displayChangedWarningWindow (prefix, button) { // Fade out warning window, if open //* DEBUG: */ alert('displayChangedWarningWindow(): prefix=' + prefix + ',button=' + button + ' - calling closeWarningWindow()'); - closeWarningWindow(prefix); + closeWarningWindow(prefix, true, false); // Fade error out for eye-candy, if open - closeErrorWindow(prefix); + closeErrorWindow(prefix, true, false); // Fade it out for eye-candy - closeProcessWindow(prefix); + closeProgressWindow(prefix, true, false); // Abort here if warningDisplayed is still true if (isElementVisible(prefix, 'warning')) { @@ -413,14 +425,14 @@ function displayChangedWarningWindow (prefix, button) { // Displays the error window for given prefix and content function displayErrorWindow (prefix, ajax_content) { // Fade out warning window, if open - //* DEBUG: */ alert('displayErrorWindow(): prefix=' + prefix + ' - calling closeWarningWindow()'); - closeWarningWindow(prefix); + //* DEBUG: */ alert('displayErrorWindow(): prefix=' + prefix + ',ajax_content=' + ajax_content.reply_content + ' - calling closeWarningWindow()'); + closeWarningWindow(prefix, true, false); // Fade it out for eye-candy - closeErrorWindow(prefix); + closeErrorWindow(prefix, true, false); // Fade it out for eye-candy - closeProcessWindow(prefix); + closeProgressWindow(prefix, true, false); // Abort here if errorDisplayed is still true if (isElementVisible(prefix, 'error')) { @@ -441,65 +453,65 @@ function displayErrorWindow (prefix, ajax_content) { }); } -// Displays the process window for given prefix and content -function displayProcessWindow (prefix, ajax_content) { +// Displays the progress window for given prefix and content +function displayProgressWindow (prefix, ajax_content) { // Fade out warning window, if open - //* DEBUG: */ alert('displayProcessWindow(): prefix=' + prefix + ' - calling closeWarningWindow()'); - closeWarningWindow(prefix); + //* DEBUG: */ alert('displayProgressWindow(): prefix=' + prefix + ' - calling closeWarningWindow()'); + closeWarningWindow(prefix, true, false); // Fade it out for eye-candy - closeErrorWindow(prefix); + closeErrorWindow(prefix, true, false); // Fade it out for eye-candy - closeProcessWindow(prefix); + closeProgressWindow(prefix, true, false); - // Abort here if processDisplayed is still true - if (isElementVisible(prefix, 'process')) { + // Abort here if progressDisplayed is still true + if (isElementVisible(prefix, 'progress')) { // Make sure this doesn't happen return; } // END - if - // Copy the response text to the process variable + // Copy the response text to the progress variable if (ajax_content.reply_content != undefined) { // Set HTML content - setProcessContent(prefix, ajax_content.reply_content); + setProgressContent(prefix, ajax_content.reply_content); } else { - setProcessContent(prefix, ajax_content); + setProgressContent(prefix, ajax_content); } - // Fade the process in - $('#' + prefix + '_process').fadeIn('slow', function() { + // Fade the progress in + $('#' + prefix + '_progress').fadeIn('slow', function() { // Do nothing for now }); } -// Sets "process content" -function setProcessContent (prefix, content) { +// Sets "progress content" +function setProgressContent (prefix, content) { // Set HTML content - $('#' + prefix + '_process_content').html(content); + $('#' + prefix + '_progress_content').html(content); } // Waits until the window has been closed -function closeErrorLocked () { +function closeErrorLocked (prefix) { // Has all been loaded? if (!isElementVisible(prefix, 'error')) { // Then release ready() $.holdReady(false); } else { // Recursive call again - window.setTimeout('closeErrorLocked()', 10); + window.setTimeout('closeErrorLocked(' + prefix + ')', 10); } } // Waits until the window has been closed -function closeProcessLocked () { +function closeProgressLocked (prefix) { // Has all been loaded? - if (!isElementVisible(prefix, 'process')) { + if (!isElementVisible(prefix, 'progress')) { // Then release ready() $.holdReady(false); } else { // Recursive call again - window.setTimeout('closeProcessLocked()', 10); + window.setTimeout('closeProgressLocked(' + prefix + ')', 10); } } @@ -524,15 +536,15 @@ function closeErrorWindow (prefix, waitClose, resetCurrentTabId) { // Shall this animation be "synchronized"? if (waitClose == true) { // Wait for the window has been closed - closeErrorLocked(); + closeErrorLocked(prefix); } // END - if } // END - if } -// Closes an process window -function closeProcessWindow (prefix, waitClose, resetCurrentTabId) { - // Is the process displayed? - if (isElementVisible(prefix, 'process')) { +// Closes an progress window +function closeProgressWindow (prefix, waitClose, resetCurrentTabId) { + // Is the progress displayed? + if (isElementVisible(prefix, 'progress')) { // Shall we wait ("sync") until the animation has completed? if (waitClose == true) { // Hold the ready status @@ -540,7 +552,7 @@ function closeProcessWindow (prefix, waitClose, resetCurrentTabId) { } // END - if // Yes, then fade it out - $('#' + prefix + '_process').fadeOut('fast', function() { + $('#' + prefix + '_progress').fadeOut('fast', function() { // Set current tab id to default if (resetCurrentTabId == true) { setCurrentTabId(defaultTabId); @@ -550,20 +562,20 @@ function closeProcessWindow (prefix, waitClose, resetCurrentTabId) { // Shall this animation be "synchronized"? if (waitClose == true) { // Wait for the window has been closed - closeProcessLocked(); + closeProgressLocked(prefix); } // END - if } // END - if } // Waits until the window has been closed -function closeWarningLocked () { +function closeWarningLocked (prefix) { // Has all been loaded? if (!isElementVisible(prefix, 'warning')) { // Then release ready() $.holdReady(false); } else { // Recursive call again - window.setTimeout('closeWarningLocked()', 10); + window.setTimeout('closeWarningLocked(' + prefix + ')', 10); } } @@ -591,7 +603,7 @@ function closeWarningWindow (prefix, waitClose, resetCurrentTabId) { if (waitClose == true) { // Wait for the window has been closed //* DEBUG: */ alert('prefix=' + prefix + ',waitClose=' + waitClose + ' - LOCKED!'); - closeWarningLocked(); + closeWarningLocked(prefix); } // END - if } // END - if } @@ -608,8 +620,8 @@ function doFooterPage (prefix, htmlId, button) { return; } // END - if - // Is process working? - if (isElementVisible(prefix, 'process')) { + // Is progress working? + if (isElementVisible(prefix, 'progress')) { // Then exit silently return; } // END - if @@ -692,8 +704,8 @@ function markFormFieldsFailed (failedFields) { }); } -// Processes the content from AJAX call -function processAjaxResponseContent (prefix, ajax_content) { +// Progresses the content from AJAX call +function progressAjaxResponseContent (prefix, ajax_content) { // By default all is failed var isResponseDone = false; @@ -718,8 +730,8 @@ function processAjaxResponseContent (prefix, ajax_content) { // Saves changes by sending the data to the AJAX backend script function saveChanges (prefix) { - // Is process working? - if (isElementVisible(prefix, 'process')) { + // Is progress working? + if (isElementVisible(prefix, 'progress')) { // Then exit silently return; } // END - if @@ -751,8 +763,8 @@ function saveChanges (prefix) { // Get the content var ajax_content = getAjaxContent(); - // Process the returned content - if (processAjaxResponseContent(prefix, ajax_content) == true) { + // Progress the returned content + if (progressAjaxResponseContent(prefix, ajax_content) == true) { // Mark all elements as unchanged markAllElementsAsUnchanged(); @@ -768,7 +780,7 @@ function saveChanges (prefix) { displayErrorWindow(prefix, '
' + ajax_content.message + '
'); } else { // This didn't work, why? - displayErrorWindow(prefix, '
processAjaxResponseContent() failed, please fix this.
\n' + lastErrorMessage + '
'); + displayErrorWindow(prefix, '
progressAjaxResponseContent() failed, please fix this.
\n' + lastErrorMessage + '
'); } } @@ -816,8 +828,8 @@ function doSaveChangesPage (prefix, htmlId, page) { // Saves changed settings and continues with given tab function doSaveChangesContinue (prefix, htmlId, tab) { - // Is process working? - if (isElementVisible(prefix, 'process')) { + // Is progress working? + if (isElementVisible(prefix, 'progress')) { // Then exit silently return; } // END - if diff --git a/js/install-common.js b/js/install-common.js index af478d3046..f01a38b3fb 100644 --- a/js/install-common.js +++ b/js/install-common.js @@ -27,75 +27,118 @@ */ // Installation steps array -var installSteps = new Array(); +var installationSteps = new Array(); // Failed step var failedStep = ''; var counterSuccess = 0; // Init all installation steps -installSteps[0] = 'import_tables_sql'; -installSteps[1] = 'import_menu_sql'; -installSteps[2] = 'write_local_config'; -installSteps[3] = 'install_extensions'; +installationSteps[0] = 'import_tables_sql'; +installationSteps[1] = 'import_menu_sql'; +installationSteps[2] = 'install_extensions'; + +// Always keep as last step +installationSteps[installationSteps.length] = 'write_local_config'; // Switches instaler by redirecting function switchInstaller (installer) { // Switch installer - document.location.href='install.php?installer=' + installer; + document.location.href = 'install.php?installer=' + installer; } // User has clicked on 'finish' function doFinishInstallation () { // First disable all buttons button - disableElement('input#next_page'); - disableElement('input#previous_page'); - disableElement('input#finish'); + resetFooterNavigation(); - // Display process window - displayProcessWindow('install', ''); + // Display progress window + displayProgressWindow('install', 'Init ...'); // Start installation loop delayed - window.setTimeout("doInstallationLoop()", 500); + window.setTimeout('doInstallationLoop()', 500); - // Is success counter same as array size - if (counterSuccess != installSteps.length) { - // Display error message - displayErrorWindow('install', getAjaxContent()); + // Wait here + window.setTimeout('doWait()', 500); +} + +// Do wait +function doWait () { + // Is still something to do? + if ((failedStep == '') && (counterSuccess != installationSteps.length)) { + // Wait one round more + window.setTimeout('doWait()', 500); + } else if ((failedStep == '') && (counterSuccess == installationSteps.length)) { + // Close window + closeProgressWindow('install', true, false); + + // Redirect to old 'finished' page + document.location.href = 'admin.php'; + } else if (failedStep != '') { + // Something happens that should not happen! + displayErrorWindow('install', 'failedStep=' + failedStep); } } +// Update progress bar +function updateProgressBar () { + // Increment counter + counterSuccess++; + + // Do only update <= 100% values + if (counterSuccess <= installationSteps.length) { + // Update progress bar + $('#progressbar').progressbar({ + value: (counterSuccess / installationSteps.length * 100) + }); + } // END - if +} + // Does the "installation loop" function doInstallationLoop () { // For-loop for all installation steps - for (var i = 0; i < installSteps.length; i++) { + for (var i = 0; i < installationSteps.length; i++) { // Output message - outputInstallationStepMessage(installSteps[i]); + outputInstallationStepMessage(installationSteps[i]); // Initialize next step - if (!sendInstallationStepRequest(installSteps[i]) == true) { + if (!sendInstallationStepRequest(i) == true) { // Failed step, so remember it for later display - failedStep = installSteps[i]; + failedStep = installationSteps[i]; // Stop here break; - } - - // Did went okay - counterSuccess++; + } // END - if // Wait a little + $('body').delay(500); + + // Update progress bar + updateProgressBar(); } // END - for + + // Is success counter same as array size + if (counterSuccess != installationSteps.length) { + // Display error message + displayErrorWindow('install', getAjaxContent() + ':' + counterSuccess + '/' + installationSteps.length + ':' + failedStep); + } // END - if } // Sends an "installation step" request out -function sendInstallationStepRequest (step) { +function sendInstallationStepRequest (i) { + // Is it set? + if (installationSteps[i] == undefined) { + // Not set installation step, so don't send it out + throw new 'installationSteps[' + i + '] is not set.'; + } // END - if + // Send out the request - return sendAjaxRequest('install', 'do_step', '&step=' + step, true); + return sendAjaxRequest('install', 'do_step', '&step=' + installationSteps[i], true); } // Outputs a "step message" function outputInstallationStepMessage (step) { // Set content - setProcessContent('install', step); + // @TODO Progress bar is out-of-order: + '
' + setProgressContent('install', step); } diff --git a/js/install-data.js b/js/install-data.js index 7d2ca7cc2f..4c801ca69e 100644 --- a/js/install-data.js +++ b/js/install-data.js @@ -34,18 +34,23 @@ indexTranslation[1] = 'base_data'; indexTranslation[2] = 'database_config'; indexTranslation[3] = 'smtp_config'; indexTranslation[4] = 'other_config'; -indexTranslation[5] = 'overview'; -indexTranslation[6] = 'finish'; +indexTranslation[5] = 'extensions'; +indexTranslation[6] = 'overview'; -// 'next page' linking, key is current page, value is the next page -var nextPage = new Array(); +// Always last ... +indexTranslation[indexTranslation.length] = 'finish'; + +// 'next/previous page' linking, key is current page, value is the next page +var nextPage = new Array(); +var previousPage = new Array(); // Add all 'next page' entries nextPage['welcome'] = 'base_data'; nextPage['base_data'] = 'database_config'; nextPage['database_config'] = 'smtp_config'; nextPage['smtp_config'] = 'other_config'; -nextPage['other_config'] = 'overview'; +nextPage['other_config'] = 'extensions'; +nextPage['extensions'] = 'overview'; nextPage['overview'] = 'finish'; // 'previous page' linking, key is current page, value is the previous page @@ -56,5 +61,6 @@ previousPage['base_data'] = 'welcome'; previousPage['database_config'] = 'base_data'; previousPage['smtp_config'] = 'database_config'; previousPage['other_config'] = 'smtp_config'; -previousPage['overview'] = 'other_config'; +previousPage['extensions'] = 'other_config'; +previousPage['overview'] = 'extensions'; previousPage['finish'] = 'overview'; diff --git a/templates/de/emails/admin/admin_sponsor_edit.tpl b/templates/de/emails/admin/admin_sponsor_edit.tpl index 4cdc65597a..a20e0557fc 100644 --- a/templates/de/emails/admin/admin_sponsor_edit.tpl +++ b/templates/de/emails/admin/admin_sponsor_edit.tpl @@ -27,7 +27,7 @@ Es sind nun folgende Daten gesetzt: ------------------------------ {--SPONSOR_WARNING_INTERVAL--}: $content[warning_interval] ------------------------------ -{--PASS_1--}: $content[pass1] +{--PASS_1--}: $content[password1] ------------------------------ Mit freundlichen Grüßen, diff --git a/templates/de/emails/member/member_mydata_notify.tpl b/templates/de/emails/member/member_mydata_notify.tpl index 809c23d2be..8447179678 100644 --- a/templates/de/emails/member/member_mydata_notify.tpl +++ b/templates/de/emails/member/member_mydata_notify.tpl @@ -12,7 +12,7 @@ Hallo {%user,gender,translateGender=$userid%} {%user,surname=$userid%} {%user,fa {--ZIP--}: {%user,zip,bigintval=$userid%} {--CITY--}: {%user,city=$userid%} {--EMAIL--}: {%user,email=$userid%} -{--PASS_1--}: $content[pass1] +{--PASS_1--}: $content[password1] ------------------------------------------ IP-Nummer: {%server,remote_addr%} (Real: {%server,real_ip_address%}) ------------------------------------------ diff --git a/templates/de/html/admin/admin_add_admins.tpl b/templates/de/html/admin/admin_add_admins.tpl index f91dacbcf2..be6d1b8996 100644 --- a/templates/de/html/admin/admin_add_admins.tpl +++ b/templates/de/html/admin/admin_add_admins.tpl @@ -21,13 +21,13 @@ {--ADMIN_ADMINS_ENTER_PASSWORD1--}: - + {--ADMIN_ADMINS_ENTER_PASSWORD2--}: - + diff --git a/templates/de/html/admin/admin_add_sponsor.tpl b/templates/de/html/admin/admin_add_sponsor.tpl index 5455b6bd07..696e1e96ad 100644 --- a/templates/de/html/admin/admin_add_sponsor.tpl +++ b/templates/de/html/admin/admin_add_sponsor.tpl @@ -144,8 +144,8 @@ {--SPONSOR_ENTER_PASSWORDS--}: - - + + diff --git a/templates/de/html/admin/admin_add_tester_user.tpl b/templates/de/html/admin/admin_add_tester_user.tpl index 846d6745ac..7add97cbef 100644 --- a/templates/de/html/admin/admin_add_tester_user.tpl +++ b/templates/de/html/admin/admin_add_tester_user.tpl @@ -78,12 +78,12 @@
- +
- +
diff --git a/templates/de/html/admin/admin_edit_admins_row.tpl b/templates/de/html/admin/admin_edit_admins_row.tpl index eb3fe5ae17..8131504576 100644 --- a/templates/de/html/admin/admin_edit_admins_row.tpl +++ b/templates/de/html/admin/admin_edit_admins_row.tpl @@ -7,8 +7,8 @@ - - + + $content[access_mode] diff --git a/templates/de/html/admin/admin_edit_sponsor_edit.tpl b/templates/de/html/admin/admin_edit_sponsor_edit.tpl index db9a033bd0..941ad76f15 100644 --- a/templates/de/html/admin/admin_edit_sponsor_edit.tpl +++ b/templates/de/html/admin/admin_edit_sponsor_edit.tpl @@ -132,8 +132,8 @@ {--SPONSOR_ENTER_PASSWORDS--}:  - - + + diff --git a/templates/de/html/admin/admin_edit_user.tpl b/templates/de/html/admin/admin_edit_user.tpl index f4be578df9..93c1ae5dc8 100644 --- a/templates/de/html/admin/admin_edit_user.tpl +++ b/templates/de/html/admin/admin_edit_user.tpl @@ -62,13 +62,13 @@ {--ADMIN_ENTER_PASSWORD1--}: - + {--ADMIN_ENTER_PASSWORD2--}: - + diff --git a/templates/de/html/admin/admin_reg_form.tpl b/templates/de/html/admin/admin_reg_form.tpl index 0a2352dec7..5da1d8e72d 100644 --- a/templates/de/html/admin/admin_reg_form.tpl +++ b/templates/de/html/admin/admin_reg_form.tpl @@ -17,17 +17,17 @@ {--ADMIN_ACCOUNT_FIRST_CREATION_PASSWORD1--}: - + - $content[pass1_message] + $content[password1_message] {--ADMIN_ACCOUNT_FIRST_CREATION_PASSWORD2--}: - + - $content[pass2_message] + $content[password2_message] diff --git a/templates/de/html/admin/admin_reset_password_form.tpl b/templates/de/html/admin/admin_reset_password_form.tpl index 626eb4e870..3e9694ebc7 100644 --- a/templates/de/html/admin/admin_reset_password_form.tpl +++ b/templates/de/html/admin/admin_reset_password_form.tpl @@ -20,7 +20,7 @@ {--ADMIN_ENTER_NEW_PASSWORD1--} - + @@ -28,7 +28,7 @@ {--ADMIN_ENTER_NEW_PASSWORD2--} - + diff --git a/templates/de/html/ext/ext_lead.tpl b/templates/de/html/ext/ext_lead.tpl index cc4189a72c..32273b0b41 100644 --- a/templates/de/html/ext/ext_lead.tpl +++ b/templates/de/html/ext/ext_lead.tpl @@ -1,31 +1,32 @@
-Diese Erweiterung bietet Ihnen die Möglichkeit an, Lead-Code von -Sponsornetzwerken in die Mitgliederanmeldung einzubinden. Dazu müssen -Sie derzeit den Lead-Code in das Template lead_code.tpl einbinden -(mehrere Lead-Codes sind auch möglich!). + Diese Erweiterung bietet Ihnen die Möglichkeit an, Lead-Code von + Sponsornetzwerken in die Mitgliederanmeldung einzubinden. Dazu müssen + Sie derzeit den Lead-Code in das Template lead_code.tpl einbinden + (mehrere Lead-Codes sind auch möglich!).
-Meistens müssen Sie irgentwelche eindeutigen Daten an den Lead-Code -übergeben. Dies können z.B. doe User-Id und/oder die Email-Adresse -sein. Beides wird von diesem Script derzeit auch unterstützt. + Meistens müssen Sie irgentwelche eindeutigen Daten an den Lead-Code + übergeben. Dies können z.B. doe User-Id und/oder die + Email-Adresse sein. Beides wird von diesem Script derzeit auch + unterstützt.
-Wenn Sie die User-Id übertragen möchten, so verwenden Sie die -Template-Variable lead_userid, möchten Sie die Email-Adresse von der -Anmeldung übertragen, verwenden Sie lead_email. Dazu ein -Beispielcode: + Wenn Sie die User-Id übertragen möchten, so verwenden Sie die + Template-Variable lead_userid, möchten Sie die Email-Adresse + von der Anmeldung übertragen, verwenden Sie lead_email. Dazu + ein Beispielcode:
<img border="0" alt="Lead" width="1" height="1" - src="http://some-sponsor-network/lead-image.php?campaign=xxx&user_data=$content[lead_userid]_$content[lead_email]" /> + src="http://some-sponsor-network/lead-image.php?campaign=xxx&amp;user_data=$content[lead_userid]_$content[lead_email]" />
-Sollten Sie dazu noch Fragen haben, so kommen Sie doch einfach in das -Forum. Ich beantworte Ihnen gerne Ihre Fragen dazu und helfe Ihnen bei -Schwierigkeiten weiter. + Sollten Sie dazu noch Fragen haben, so kommen Sie doch einfach in das Forum. Ich beantworte + Ihnen gerne Ihre Fragen dazu und helfe Ihnen bei Schwierigkeiten weiter.
diff --git a/templates/de/html/ext/ext_primera.tpl b/templates/de/html/ext/ext_primera.tpl index 26a01f3ee3..11f5d85d80 100644 --- a/templates/de/html/ext/ext_primera.tpl +++ b/templates/de/html/ext/ext_primera.tpl @@ -1,14 +1 @@ -
- Mit dieser Erweiterung können Sie Ihren Mitgliedern eine Auszahlung - ihrer Internet-Währung Primera auf ihr Primera-Account - überweisen lassen. Sie als Primera-Anbieter brauchen dazu - selbstverständlich ein Primera-Account. Mehr dazu auf - www.primusportal.de. Wenn - Sie möchten, können Sie auch ganz zu Primera wechseln. Dazu - geben Sie unter Sonstige - Einstellungen, "Währung Ihres - {OPEN_CONFIG}mt_word2{CLOSE_CONFIG}" einfach das Wort Primera ein. -
+ diff --git a/templates/de/html/guest/guest_register.tpl b/templates/de/html/guest/guest_register.tpl index 00e614e5d1..e23df8a14b 100644 --- a/templates/de/html/guest/guest_register.tpl +++ b/templates/de/html/guest/guest_register.tpl @@ -121,8 +121,8 @@ {--PASS_1--}, {--PASS_2--}: - - + + diff --git a/templates/de/html/guest/guest_sponsor_reg.tpl b/templates/de/html/guest/guest_sponsor_reg.tpl index 97908bc1fe..61d520219d 100644 --- a/templates/de/html/guest/guest_sponsor_reg.tpl +++ b/templates/de/html/guest/guest_sponsor_reg.tpl @@ -158,8 +158,8 @@ {--SPONSOR_ENTER_PASSWORDS--}: - - + + diff --git a/templates/de/html/install/install_list_extensions.tpl b/templates/de/html/install/install_list_extensions.tpl new file mode 100644 index 0000000000..abefc87a34 --- /dev/null +++ b/templates/de/html/install/install_list_extensions.tpl @@ -0,0 +1,17 @@ +
+ + + + + + +$content + + + +
{--ID_SELECT--}{--ADMIN_EXTENSION_NAME--}{--ADMIN_EXTENSION_VERSION--}
+
diff --git a/templates/de/html/install/install_list_extensions_row.tpl b/templates/de/html/install/install_list_extensions_row.tpl new file mode 100644 index 0000000000..f41fe45b93 --- /dev/null +++ b/templates/de/html/install/install_list_extensions_row.tpl @@ -0,0 +1,17 @@ + + + + + + $content[ext_name] + + + $content[ext_version] + + + + + + $content[description] + + diff --git a/templates/de/html/install/install_main_ajax.tpl b/templates/de/html/install/install_main_ajax.tpl index f080c43cf9..1016e03926 100644 --- a/templates/de/html/install/install_main_ajax.tpl +++ b/templates/de/html/install/install_main_ajax.tpl @@ -9,7 +9,7 @@ -
+
-
+
-
-
+