From 1bf7c189fda17ce6c702f600c0eb084b681a307b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Sun, 22 Nov 2009 07:31:42 +0000 Subject: [PATCH] A lot templates rewritten, TODOs.txt updated, XHTML fixes: - A lot more configurations are now parsed by FILTER_COMPILE_EXTENSION () (we really need to rename this function) - The same with user data - HTML tag 'SMALL' fixed to a div - Codes 'ID_UNCONFIRMED' and 'ID_LOCKED' renamed to 'STATUS_xxx' - TODOs.txt updated --- DOCS/TODOs.txt | 39 +++-- inc/databases.php | 71 ++++---- inc/filters.php | 154 ++++++++++-------- inc/functions.php | 55 +++---- inc/language/de.php | 5 +- inc/libs/nickname_functions.php | 2 +- inc/libs/wernis_functions.php | 5 +- inc/mails/beg_mails.php | 5 - inc/modules/admin/what-config_payouts.php | 2 +- inc/modules/admin/what-config_wernis.php | 2 +- inc/modules/member/what-beg.php | 40 +---- inc/modules/member/what-doubler.php | 4 +- inc/modules/member/what-html_mail.php | 6 - inc/modules/member/what-mydata.php | 19 +-- inc/modules/member/what-payout.php | 2 +- inc/modules/member/what-points.php | 8 - inc/modules/member/what-primera.php | 18 +- inc/modules/member/what-refback.php | 2 - inc/modules/member/what-reflinks.php | 7 - inc/modules/member/what-transfer.php | 6 - inc/modules/member/what-wernis.php | 28 +--- inc/reset/reset_100_bonus.php | 3 - inc/reset/reset_birthday.php | 1 - templates/de/emails/beg/beg_en_notify.tpl | 6 +- .../emails/member/member_birthday_confirm.tpl | 2 +- .../de/emails/member/member_stats_bonus.tpl | 2 +- templates/de/html/guest/guest_goto_top.tpl | 5 +- templates/de/html/member/member_beg.tpl | 8 +- templates/de/html/member/member_doubler.tpl | 4 +- templates/de/html/member/member_goto_top.tpl | 5 +- .../de/html/member/member_holiday_form.tpl | 3 +- .../de/html/member/member_mydata_edit.tpl | 122 +++++--------- .../de/html/member/member_mydata_locked.tpl | 12 +- templates/de/html/member/member_points.tpl | 94 +++-------- .../member/member_points_bonus_disabled.tpl | 5 +- .../html/member/member_points_bonus_rows.tpl | 70 ++------ .../de/html/member/member_points_row.tpl | 11 +- .../de/html/member/member_points_upgrade.tpl | 9 +- .../html/member/member_primera_mode_pay.tpl | 10 +- .../de/html/member/member_refback_edit.tpl | 40 ++--- templates/de/html/member/member_reflink.tpl | 2 +- .../html/member/member_wernis_mode_payout.tpl | 8 +- .../member/member_wernis_mode_withdraw.tpl | 5 +- 43 files changed, 327 insertions(+), 580 deletions(-) diff --git a/DOCS/TODOs.txt b/DOCS/TODOs.txt index b2881bb88d..7389c077a0 100644 --- a/DOCS/TODOs.txt +++ b/DOCS/TODOs.txt @@ -16,7 +16,8 @@ ./inc/extensions/ext-yoomedia.php:55:// @TODO Only deprecated when 'network' is ready! setExtensionDeprecated('Y'); ./inc/extensions-functions.php:376:// @TODO Change from ext_id to ext_name (not just even the variable! ;-) ) ./inc/extensions-functions.php:489: // @TODO Extension is loaded, what next? -./inc/filters.php:465: // @TODO This whole if-block is very static +./inc/filters.php:473: // @TODO This whole switch-block is very static +./inc/filters.php:538: case 'config': // @TODO FILTER_COMPILE_CONFIG does not handle call-back functions so we handle it here again ./inc/functions.php:1033: // @TODO Do only use $content and deprecate $GLOBALS and $DATA in templates ./inc/functions.php:241: // @TODO Remove this sanity-check if all is fine ./inc/functions.php:2431:// @TODO Please describe this function @@ -24,20 +25,20 @@ ./inc/functions.php:244: // @TODO Try to rewrite all $DATA to $content ./inc/functions.php:2563: // @TODO Add a little more infos here ./inc/functions.php:2586: // @TODO This cannot be rewritten to app_die(), try to find a solution for this. -./inc/functions.php:2666: // @TODO Rewrite this old lost code to a template -./inc/functions.php:2755: // @TODO Are these convertions still required? -./inc/functions.php:2773:// @TODO Rewrite this function to use readFromFile() and writeToFile() -./inc/functions.php:3651:// @TODO Lame description for this function -./inc/functions.php:3673: // @TODO Move this in a filter -./inc/functions.php:3791: // @TODO This is still very static, rewrite it somehow +./inc/functions.php:2665: // @TODO Rewrite this old lost code to a template +./inc/functions.php:2754: // @TODO Are these convertions still required? +./inc/functions.php:2772:// @TODO Rewrite this function to use readFromFile() and writeToFile() +./inc/functions.php:3650:// @TODO Lame description for this function +./inc/functions.php:3672: // @TODO Move this in a filter +./inc/functions.php:3790: // @TODO This is still very static, rewrite it somehow ./inc/functions.php:456: // @TODO Do only use $content, not $DATA or raw variables ./inc/functions.php:526: // @TODO Extension 'msg' does not exist ./inc/functions.php:595:// @TODO Rewrite this to an extension 'smtp' ./inc/functions.php:998:// @TODO $simple is deprecated ./inc/install-functions.php:62: // @TODO DEACTIVATED: changeDataInFile(getConfig('CACHE_PATH') . 'config-local.php', '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 five constants -./inc/language/de.php:847:// @TODO Are these constants longer used? +./inc/language/de.php:1146:// @TODO Rewrite these two constants +./inc/language/de.php:1162:// @TODO Rewrite these five constants +./inc/language/de.php:846:// @TODO Are these constants longer used? ./inc/language-functions.php:228: // @TODO These are all valid languages, again hard-coded ./inc/language-functions.php:45:// @TODO Rewrite all language constants to this function. ./inc/language/holiday_de.php:49:// @TODO Rewrite these two constants to one @@ -143,20 +144,21 @@ ./inc/modules/guest/what-sponsor_reg.php:286: // @TODO Swap this HTML code to templates ./inc/modules/guest/what-stats.php:115: // @TODO This can be somehow rewritten ./inc/modules/guest/what-stats.php:75:// @TODO This can be rewritten in a dynamic include -./inc/modules/member/what-beg.php:89:// @TODO No more needed? define('__BEG_UID_TIMEOUT', createFancyTime(getConfig('beg_userid_timeout'))); +./inc/modules/member/what-beg.php:63:// @TODO No more needed? define('__BEG_UID_TIMEOUT', createFancyTime(getConfig('beg_userid_timeout'))); ./inc/modules/member/what-bonus.php:56: // @TODO Rewrite this to a filter ./inc/modules/member/what-categories.php:128: // @TODO Rewrite this to use $OUT .= ... +./inc/modules/member/what-doubler.php:55:// @TODO The '*100' is in the way to get moved into the template ./inc/modules/member/what-order.php:443: // @TODO Rewrite this to a filter ./inc/modules/member/what-payout.php:240: // @TODO Rewrite this to a filter ./inc/modules/member/what-points.php:54:// @TODO Should we rewrite this to a filter? ./inc/modules/member/what-rallyes.php:90: // @TODO Reactivate this: $content['admin'] = "" . $content['login'] . ""; -./inc/modules/member/what-reflinks.php:60:// @TODO Move this into a filter +./inc/modules/member/what-reflinks.php:53:// @TODO Move this into a filter ./inc/modules/member/what-stats.php:118: // @TODO Rewrite in template: clix->clicks -./inc/modules/member/what-transfer.php:141: // @TODO Rewrite this to a filter -./inc/modules/member/what-transfer.php:231: // @TODO Try to rewrite his to $content = SQL_FETCHARRAY(), see some lines above for two different queries -./inc/modules/member/what-transfer.php:316: // @TODO This should be somehow rewritten to $row = SQL_FETCHARRAY(), see switch() block above for SQL queries -./inc/modules/member/what-transfer.php:322: // @TODO Rewrite: tid->trans_id,stamp->time_trans -./inc/modules/member/what-transfer.php:99: // @TODO Rewrite this to a filter +./inc/modules/member/what-transfer.php:135: // @TODO Rewrite this to a filter +./inc/modules/member/what-transfer.php:225: // @TODO Try to rewrite his to $content = SQL_FETCHARRAY(), see some lines above for two different queries +./inc/modules/member/what-transfer.php:310: // @TODO This should be somehow rewritten to $row = SQL_FETCHARRAY(), see switch() block above for SQL queries +./inc/modules/member/what-transfer.php:316: // @TODO Rewrite: tid->trans_id,stamp->time_trans +./inc/modules/member/what-transfer.php:93: // @TODO Rewrite this to a filter ./inc/modules/member/what-unconfirmed.php:142: // @TODO Try to rewrite this to $content = SQL_FETCHARRAY() ./inc/modules/order.php:75: // @TODO Unused: 2,4 ./inc/monthly/monthly_bonus.php:68: // @TODO Rewrite this to a filter @@ -169,7 +171,7 @@ ./inc/mysql-manager.php:552: // @TODO Try to rewrite this to one or more functions ./inc/mysql-manager.php:93:// @TODO Can we cache this? ./inc/reset/reset_beg.php:50:// @TODO This should be converted in a daily beg rallye -./inc/reset/reset_birthday.php:92: // @TODO 4 is hard-coded here, should we move it out in config? +./inc/reset/reset_birthday.php:91: // @TODO 4 is hard-coded here, should we move it out in config? ./inc/wrapper-functions.php:127:// @TODO Implement $compress ./inc/wrapper-functions.php:134:// @TODO Implement $decompress ./inc/wrapper-functions.php:393:// @TODO Do some more sanity check here @@ -204,6 +206,7 @@ ./templates/de/html/surfbar/surfbar_frame_top.tpl:23:// @TODO Try to rewrite this JavaScript to js.php?js=surfbar_frame_top (wouldn't be easy) ### ### DEPRECATION FOLLOWS: ### ### ./inc/modules/admin/admin-inc.php:532:// @DEPRECATED +./templates/de/html/member/member_mydata_locked.tpl:1: ### ### template-warnings.log follows: ### ### Warning: DOMDocument::loadHTMLFile(): Unexpected end tag : td in templates/de/html/menu/menu_what_end.tpl, line: 1 in Warning: DOMDocument::loadHTMLFile(): Unexpected end tag : tr in templates/de/html/menu/menu_what_end.tpl, line: 2 in diff --git a/inc/databases.php b/inc/databases.php index b5dcf2efb4..50455b04a3 100644 --- a/inc/databases.php +++ b/inc/databases.php @@ -42,41 +42,40 @@ if (!defined('__SECURITY')) { } // END - if // System-wide return codes -addCode('WRONG_PASS' , 0x001); -addCode('WRONG_ID' , 0x002); -addCode('ID_LOCKED' , 0x003); -addCode('ID_UNCONFIRMED' , 0x004); -addCode('UNKNOWN_STATUS' , 0x005); -addCode('CNTR_FAILED' , 0x008); -addCode('LOGOUT_DONE' , 0x008); -addCode('LOGOUT_FAILED' , 0x009); -addCode('URL_TLOCK' , 0x00a); -addCode('URL_FOUND' , 0x00b); -addCode('OVERLENGTH' , 0x00c); -addCode('SUBJ_URL' , 0x00d); -addCode('BLIST_URL' , 0x00e); -addCode('NO_RECS_LEFT' , 0x00f); -addCode('INVALID_TAGS' , 0x010); -addCode('MORE_POINTS' , 0x011); -addCode('COOKIES_DISABLED' , 0x012); -addCode('DATA_INVALID' , 0x013); -addCode('POSSIBLE_INVALID' , 0x014); -addCode('ACCOUNT_LOCKED' , 0x015); -addCode('USER_404' , 0x016); -addCode('STATS_404' , 0x017); -addCode('ALREADY_CONFIRMED', 0x018); -addCode('ERROR_MAILID' , 0x019); -addCode('EXTENSION_PROBLEM', 0x01a); -addCode('MORE_RECEIVERS1' , 0x01b); -addCode('MORE_RECEIVERS2' , 0x01c); -addCode('MORE_RECEIVERS3' , 0x01d); -addCode('INVALID_URL' , 0x01e); -addCode('MENU_NOT_VALID' , 0x01f); -addCode('LOGIN_FAILED' , 0x020); -addCode('BEG_SAME_AS_OWN' , 0x021); -addCode('UNHANDLED_STATUS' , 0x022); -addCode('MODULE_MEM_ONLY' , 0x023); -addCode('ID_GUEST' , 0x024); +addCode('WRONG_PASS' , 0x001); +addCode('WRONG_ID' , 0x002); +addCode('STATUS_LOCKED' , 0x003); +addCode('STATUS_UNCONFIRMED', 0x004); +addCode('UNKNOWN_STATUS' , 0x005); +addCode('CNTR_FAILED' , 0x008); +addCode('LOGOUT_DONE' , 0x008); +addCode('LOGOUT_FAILED' , 0x009); +addCode('URL_TLOCK' , 0x00a); +addCode('URL_FOUND' , 0x00b); +addCode('OVERLENGTH' , 0x00c); +addCode('SUBJ_URL' , 0x00d); +addCode('BLIST_URL' , 0x00e); +addCode('NO_RECS_LEFT' , 0x00f); +addCode('INVALID_TAGS' , 0x010); +addCode('MORE_POINTS' , 0x011); +addCode('COOKIES_DISABLED' , 0x012); +addCode('DATA_INVALID' , 0x013); +addCode('POSSIBLE_INVALID' , 0x014); +addCode('ACCOUNT_LOCKED' , 0x015); +addCode('USER_404' , 0x016); +addCode('STATS_404' , 0x017); +addCode('ALREADY_CONFIRMED' , 0x018); +addCode('ERROR_MAILID' , 0x019); +addCode('EXTENSION_PROBLEM' , 0x01a); +addCode('MORE_RECEIVERS1' , 0x01b); +addCode('MORE_RECEIVERS2' , 0x01c); +addCode('MORE_RECEIVERS3' , 0x01d); +addCode('INVALID_URL' , 0x01e); +addCode('MENU_NOT_VALID' , 0x01f); +addCode('LOGIN_FAILED' , 0x020); +addCode('BEG_SAME_AS_OWN' , 0x021); +addCode('UNHANDLED_STATUS' , 0x022); +addCode('MODULE_MEM_ONLY' , 0x023); // Server-URL (DO NOT CHANGE THIS OR YOU CANNOT CHECK FOR UPDATES/EXTENSIONS!) setConfigEntry('SERVER_URL', 'http://www.mxchange.org'); @@ -111,5 +110,5 @@ setConfigEntry('ENCRYPT_SEPERATOR', ':'); // Extra title is empty by default setExtraTitle(''); -// +// [EOF] ?> diff --git a/inc/filters.php b/inc/filters.php index 1b20ecccf7..8cc35e4293 100644 --- a/inc/filters.php +++ b/inc/filters.php @@ -411,7 +411,7 @@ function FILTER_COMPILE_CONFIG ($code, $compiled = false) { $GLOBALS['compile_config'][$matches[1][$key]] = "\".getConfig('" . $matches[1][$key] . "').\""; } elseif (isConfigEntrySet('default_' . strtoupper($matches[1][$key]))) { // Use default value - $GLOBALS['compile_config'][$matches[1][$key]] = "\".getConfig('" . 'DEFAULT_' . strtoupper($matches[1][$key]) . "').\""; + $GLOBALS['compile_config'][$matches[1][$key]] = "\" . getConfig('" . 'DEFAULT_' . strtoupper($matches[1][$key]) . "') . \""; } elseif (isMessageIdValid('DEFAULT_' . strtoupper($matches[1][$key]))) { // No config, try the language system $GLOBALS['compile_config'][$matches[1][$key]] = "\" . getMessage('". 'DEFAULT_' . strtoupper($matches[1][$key]) . "') . \""; @@ -458,83 +458,107 @@ function FILTER_COMPILE_EXTENSION ($code) { if ((count($matches) > 0) && (count($matches[3]) > 0)) { // Replace all matches foreach ($matches[2] as $key => $cmd) { - // Init replacer variable + // Init replacer/call-back variable $replacer = ''; + $callback = ''; + $extraFunction = ''; + + // Extract command and call-back + $cmdArray = explode(',', $cmd); + $cmd = $cmdArray[0]; + if (isset($cmdArray[1])) $callback = $cmdArray[1]; + if (isset($cmdArray[2])) $extraFunction = $cmdArray[2]; // Is the extension installed or code provided? - // @TODO This whole if-block is very static - if ($cmd == 'code') { - // Code asked for - $code = str_replace($matches[0][$key], "\" . getCode('" . $matches[4][$key] . "') . \"", $code); - } elseif (substr($cmd, 0, 3) == 'url') { - // Do we have JS-mode? - if (substr($cmd, -2, 2) == 'js') $outputMode = 1; - - // Handle an URL here - $replacer = "\" . encodeUrl(\"" . $matches[4][$key] . "\", " . $outputMode . ") . \""; - - // Replace it - $code = str_replace($matches[0][$key], $replacer, $code); - } elseif (substr($cmd, 0, 6) == 'server') { - // Get data from $_SERVER by their respective functions - $serverCmd = explode(',', $cmd); - $serverCmd = $serverCmd[1]; - - // This will make 'foo_bar' to detectFooBar() - $functionName = "'detect' . implode('', array_map('ucfirst', explode('_', '" . $serverCmd . "')))"; - - // Replace it - $code = str_replace($matches[0][$key], "\" . call_user_func(" . $functionName . ") . \"", $code); - } elseif (substr($cmd, 0, 4) == 'user') { - // Extract user command - $userCmdArray = explode(',', $cmd); - $userCmd = $userCmdArray[1]; - - // Use current userid by default - $functionName = 'getMemberId()'; - - // User-related data, so is there a userid? - if (!empty($matches[4][$key])) { - // Do we have a userid or $userid? - if ($matches[4][$key] == '$userid') { - // Use dynamic call - $functionName = "getFetchedUserData('userid', \$userid, '" . $userCmd . "')"; - } elseif ($matches[4][$key] > 0) { - // User data found - $functionName = "getFetchedUserData('userid', " . $matches[4][$key] . ", " . $userCmd . "')"; + // @TODO This whole switch-block is very static + switch ($cmd) { + case 'code': // Code asked for + $code = str_replace($matches[0][$key], "\" . getCode('" . $matches[4][$key] . "') . \"", $code); + break; + + case 'url': + // Do we have JS-mode? + if (substr($cmd, -2, 2) == 'js') $outputMode = 1; + + // Handle an URL here + $replacer = "\" . encodeUrl(\"" . $matches[4][$key] . "\", " . $outputMode . ") . \""; + + // Replace it + $code = str_replace($matches[0][$key], $replacer, $code); + break; + + case 'server': + // This will make 'foo_bar' to detectFooBar() + $functionName = "'detect' . implode('', array_map('ucfirst', explode('_', '" . $callback . "')))"; + + // Replace it + $code = str_replace($matches[0][$key], "\" . call_user_func(" . $functionName . ") . \"", $code); + break; + + case 'user': + // Use current userid by default + $functionName = 'getMemberId()'; + + // User-related data, so is there a userid? + if (!empty($matches[4][$key])) { + // Do we have a userid or $userid? + if ($matches[4][$key] == '$userid') { + // Use dynamic call + $functionName = "getFetchedUserData('userid', \$userid, '" . $callback . "')"; + } elseif ($matches[4][$key] > 0) { + // User data found + $functionName = "getFetchedUserData('userid', " . $matches[4][$key] . ", " . $callback . "')"; + } // END - if + } elseif ((!empty($callback)) && (isMember())) { + // "Call-back" alias column for current logged in user's data + $functionName = "getUserData('" . $callback . "')"; + } + + // Do we have another function to run (e.g. translations) + if (!empty($extraFunction)) { + // Surround the original function call with it + $functionName = $extraFunction . '(' . $functionName . ')'; } // END - if - } // END - if - // Do we have another function to run (e.g. translations) - if (isset($userCmdArray[2])) { - // Surround the original function call with it - $functionName = $userCmdArray[2] . '(' . $functionName . ')'; - } // END - if + // Now replace the code + $code = str_replace($matches[0][$key], "\" . " . $functionName . " . \"", $code); + break; - // Now replace the code - $code = str_replace($matches[0][$key], "\" . " . $functionName . " . \"", $code); - } elseif (substr($cmd, 0, 3) == 'ext') { - // Get the extension command - $extCmd = explode(',', $cmd); - $extCmd = $extCmd[1]; + case 'ext': + // Construct call-back function name + $functionName = 'getExtension' . ucfirst(strtolower($callback)); - // Construct call-back function name - $functionName = 'getExtension' . ucfirst(strtolower($extCmd)); + // Construct call of the function + $replacer = "\" . call_user_func_array('" . $functionName . "', array('" . $matches[4][$key] . "', true)) . \""; - // Construct call of the function - $replacer = "\" . call_user_func_array('" . $functionName . "', array('" . $matches[4][$key] . "', true)) . \""; + // Replace it and insert parameter for GET request + $code = str_replace($matches[0][$key], sprintf("&ext=%s&rev=\" . getConfig('CURR_SVN_REVISION') . \"", $replacer), $code); + break; - // Replace it and insert parameter for GET request - $code = str_replace($matches[0][$key], sprintf("&ext=%s&rev=\" . getConfig('CURR_SVN_REVISION') . \"", $replacer), $code); - } else { - // Unknown command detected - debug_report_bug('Unknown command ' . $cmd . ' detected.'); - } + case 'config': // @TODO FILTER_COMPILE_CONFIG does not handle call-back functions so we handle it here again + // Read configuration + $configValue = getConfig($matches[4][$key]); + + // Do we have a call-back? + if (!empty($callback)) { + // Parse it through this function + $configValue = call_user_func_array($callback, array($configValue)); + } // END - if + + // Replace the config entry + $code = str_replace($matches[0][$key], $configValue, $code); + break; + + default: + // Unsupported command detected + debug_report_bug('Command=' . $cmd . ', callback=' . $callback . ', extra=' . $extraFunction . ' is unsupported.'); + break; + } // END - switch } // END - foreach } // END - if // Do we have non-HTML mode? - if ((getOutputMode() != '0') || ($outputMode != '0')) $code = html_entity_decode($code); + if ((getOutputMode() != '0') || ($outputMode != '0')) $code = decodeEntities($code); // Return compiled code //* DEBUG: */ die('
'.htmlentities($code).'
'); diff --git a/inc/functions.php b/inc/functions.php index 9376897615..8b57a86193 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -2597,34 +2597,33 @@ function getMessageFromErrorCode ($code) { $message = ''; switch ($code) { case '': break; - case getCode('LOGOUT_DONE') : $message = getMessage('LOGOUT_DONE'); break; - case getCode('LOGOUT_FAILED') : $message = "{--LOGOUT_FAILED--}"; break; - case getCode('DATA_INVALID') : $message = getMessage('MAIL_DATA_INVALID'); break; - case getCode('POSSIBLE_INVALID') : $message = getMessage('MAIL_POSSIBLE_INVALID'); break; - case getCode('ACCOUNT_LOCKED') : $message = getMessage('MEMBER_ACCOUNT_LOCKED_UNC'); break; - case getCode('USER_404') : $message = getMessage('USER_404'); break; - case getCode('STATS_404') : $message = getMessage('MAIL_STATS_404'); break; - case getCode('ALREADY_CONFIRMED'): $message = getMessage('MAIL_ALREADY_CONFIRMED'); break; - case getCode('WRONG_PASS') : $message = getMessage('LOGIN_WRONG_PASS'); break; - case getCode('WRONG_ID') : $message = getMessage('LOGIN_WRONG_ID'); break; - case getCode('ID_LOCKED') : $message = getMessage('LOGIN_ID_LOCKED'); break; - case getCode('ID_UNCONFIRMED') : $message = getMessage('LOGIN_ID_UNCONFIRMED'); break; - case getCode('ID_GUEST') : $message = getMessage('LOGIN_ID_GUEST'); break; - case getCode('COOKIES_DISABLED') : $message = getMessage('LOGIN_COOKIES_DISABLED'); break; - case getCode('BEG_SAME_AS_OWN') : $message = getMessage('BEG_SAME_UID_AS_OWN'); break; - case getCode('LOGIN_FAILED') : $message = getMessage('LOGIN_FAILED_GENERAL'); break; - case getCode('MODULE_MEM_ONLY') : $message = sprintf(getMessage('MODULE_MEM_ONLY'), getRequestElement('mod')); break; - case getCode('OVERLENGTH') : $message = getMessage('MEMBER_TEXT_OVERLENGTH'); break; - case getCode('URL_FOUND') : $message = getMessage('MEMBER_TEXT_CONTAINS_URL'); break; - case getCode('SUBJ_URL') : $message = getMessage('MEMBER_SUBJ_CONTAINS_URL'); break; - case getCode('BLIST_URL') : $message = "{--MEMBER_URL_BLACK_LISTED--}
\n{--MEMBER_BLIST_TIME--}: ".generateDateTime(getRequestElement('blist'), 0); break; - case getCode('NO_RECS_LEFT') : $message = getMessage('MEMBER_SELECTED_MORE_RECS'); break; - case getCode('INVALID_TAGS') : $message = getMessage('MEMBER_HTML_INVALID_TAGS'); break; - case getCode('MORE_POINTS') : $message = getMessage('MEMBER_MORE_POINTS_NEEDED'); break; - case getCode('MORE_RECEIVERS1') : $message = getMessage('MEMBER_ENTER_MORE_RECEIVERS'); break; - case getCode('MORE_RECEIVERS2') : $message = getMessage('MEMBER_NO_MORE_RECEIVERS_FOUND'); break; - case getCode('MORE_RECEIVERS3') : $message = sprintf(getMessage('MEMBER_ENTER_MORE_MIN_RECEIVERS'), getConfig('order_min')); break; - case getCode('INVALID_URL') : $message = getMessage('MEMBER_ENTER_INVALID_URL'); break; + case getCode('LOGOUT_DONE') : $message = getMessage('LOGOUT_DONE'); break; + case getCode('LOGOUT_FAILED') : $message = '{--LOGOUT_FAILED--}'; break; + case getCode('DATA_INVALID') : $message = getMessage('MAIL_DATA_INVALID'); break; + case getCode('POSSIBLE_INVALID') : $message = getMessage('MAIL_POSSIBLE_INVALID'); break; + case getCode('ACCOUNT_LOCKED') : $message = getMessage('MEMBER_ACCOUNT_LOCKED_UNC'); break; + case getCode('USER_404') : $message = getMessage('USER_404'); break; + case getCode('STATS_404') : $message = getMessage('MAIL_STATS_404'); break; + case getCode('ALREADY_CONFIRMED') : $message = getMessage('MAIL_ALREADY_CONFIRMED'); break; + case getCode('WRONG_PASS') : $message = getMessage('LOGIN_WRONG_PASS'); break; + case getCode('WRONG_ID') : $message = getMessage('LOGIN_WRONG_ID'); break; + case getCode('STATUS_LOCKED') : $message = getMessage('LOGIN_STATUS_LOCKED'); break; + case getCode('STATUS_UNCONFIRMED'): $message = getMessage('LOGIN_STATUS_UNCONFIRMED'); break; + case getCode('COOKIES_DISABLED') : $message = getMessage('LOGIN_COOKIES_DISABLED'); break; + case getCode('BEG_SAME_AS_OWN') : $message = getMessage('BEG_SAME_UID_AS_OWN'); break; + case getCode('LOGIN_FAILED') : $message = getMessage('LOGIN_FAILED_GENERAL'); break; + case getCode('MODULE_MEM_ONLY') : $message = sprintf(getMessage('MODULE_MEM_ONLY'), getRequestElement('mod')); break; + case getCode('OVERLENGTH') : $message = getMessage('MEMBER_TEXT_OVERLENGTH'); break; + case getCode('URL_FOUND') : $message = getMessage('MEMBER_TEXT_CONTAINS_URL'); break; + case getCode('SUBJ_URL') : $message = getMessage('MEMBER_SUBJ_CONTAINS_URL'); break; + case getCode('BLIST_URL') : $message = "{--MEMBER_URL_BLACK_LISTED--}
\n{--MEMBER_BLIST_TIME--}: ".generateDateTime(getRequestElement('blist'), 0); break; + case getCode('NO_RECS_LEFT') : $message = getMessage('MEMBER_SELECTED_MORE_RECS'); break; + case getCode('INVALID_TAGS') : $message = getMessage('MEMBER_HTML_INVALID_TAGS'); break; + case getCode('MORE_POINTS') : $message = getMessage('MEMBER_MORE_POINTS_NEEDED'); break; + case getCode('MORE_RECEIVERS1') : $message = getMessage('MEMBER_ENTER_MORE_RECEIVERS'); break; + case getCode('MORE_RECEIVERS2') : $message = getMessage('MEMBER_NO_MORE_RECEIVERS_FOUND'); break; + case getCode('MORE_RECEIVERS3') : $message = sprintf(getMessage('MEMBER_ENTER_MORE_MIN_RECEIVERS'), getConfig('order_min')); break; + case getCode('INVALID_URL') : $message = getMessage('MEMBER_ENTER_INVALID_URL'); break; case getCode('ERROR_MAILID'): if (isExtensionActive('mailid', true)) { diff --git a/inc/language/de.php b/inc/language/de.php index bdee7273e9..ea24dda61e 100644 --- a/inc/language/de.php +++ b/inc/language/de.php @@ -305,9 +305,8 @@ addMessages(array( 'LOGIN_UNKNOWN_CODE' => "Unbekannter Rückgabewert.", 'LOGIN_WRONG_PASS' => "Falsches Passwort eingegben.", 'LOGIN_WRONG_ID' => "Es wurde kein Account unter Ihren eingegebenen Logindaten gefunden.", - 'LOGIN_ID_LOCKED' => "Ihr Account wurde gesperrt.", - 'LOGIN_ID_UNCONFIRMED' => "Bitte bestätigen Sie erst Ihre Email-Adresse! Haben Sie den Bestätigungslink verloren? Links im Menü unter "Bestätigungslink" können Sie ihn erneut anfordern.", - 'LOGIN_ID_GUEST' => "Es ist etwas beim Anmelden schief gelaufen. Dies sollte nicht vorkommen. status=guest", + 'LOGIN_STATUS_LOCKED' => "Ihr Account wurde gesperrt.", + 'LOGIN_STATUS_UNCONFIRMED' => "Bitte bestätigen Sie erst Ihre Email-Adresse! Haben Sie den Bestätigungslink verloren? Links im Menü unter "Bestätigungslink" können Sie ihn erneut anfordern.", 'LOGIN_COOKIES_DISABLED' => "Sie haben in Ihrem Browser entweder die Cookies ausgeschaltet, oder die Sicherheitsstufe ist zu hoch eingestellt.", 'GUEST_REG_POINTS_1' => "Für Ihre Anmeldung haben wir Ihnen als Willkommensgutschrift", 'GUEST_REG_POINTS_2' => "{?POINTS?} gutgeschrieben. Sie können bereits jetzt schon Mails an die anderen Mitglieder verschicken - solange Empfänger auch erreichbar sind.", diff --git a/inc/libs/nickname_functions.php b/inc/libs/nickname_functions.php index a75b9d75b2..9dab316538 100644 --- a/inc/libs/nickname_functions.php +++ b/inc/libs/nickname_functions.php @@ -79,7 +79,7 @@ function getNickname ($userid) { $result = false; // Nickname or userid used? - if (''.round($userid).'' === ''.$userid.'') { + if ('' . round($userid) . '' === '' . $userid . '') { // Userid given, so try to load user data if (fetchUserData($userid)) { // Load nickname from database diff --git a/inc/libs/wernis_functions.php b/inc/libs/wernis_functions.php index d9832471b9..6e37a974bf 100644 --- a/inc/libs/wernis_functions.php +++ b/inc/libs/wernis_functions.php @@ -398,15 +398,12 @@ function WERNIS_ADD_FEES_TO_ARRAY (&$array) { } // END - if // Add both factors - $array['payout_factor'] = translateComma(getConfig('wernis_payout_factor')); $array['withdraw_factor'] = translateComma(getConfig('wernis_withdraw_factor')); // Add all fees - $array['payout_fee_percent'] = translateComma(getConfig('wernis_payout_fee_percent')); $array['withdraw_fee_percent'] = translateComma(getConfig('wernis_withdraw_fee_percent')); - $array['payout_fee_fix'] = translateComma(getConfig('wernis_payout_fee_fix')); $array['withdraw_fee_fix'] = translateComma(getConfig('wernis_withdraw_fee_fix')); } -// +// [EOF] ?> diff --git a/inc/mails/beg_mails.php b/inc/mails/beg_mails.php index 9bf3915639..f29ca38451 100644 --- a/inc/mails/beg_mails.php +++ b/inc/mails/beg_mails.php @@ -80,11 +80,6 @@ if (!empty($sql)) { // The SQL command needs to be finisched here (only confirmed accounts!) $sql .= ") AND `status`='CONFIRMED' ORDER BY `last_online` ASC"; - // Prepare data for the template - $content['min_points'] = translateComma(getConfig('beg_points')); - $content['max_points'] = translateComma(getConfig('beg_points_max')); - $content['max_winner'] = round(getConfig('beg_ranks')); - // No IP locking setuped by default $content['ip_locker'] = getMessage('BEG_NO_LIMITATION'); diff --git a/inc/modules/admin/what-config_payouts.php b/inc/modules/admin/what-config_payouts.php index 461184e9b9..5f8cef9747 100644 --- a/inc/modules/admin/what-config_payouts.php +++ b/inc/modules/admin/what-config_payouts.php @@ -245,7 +245,7 @@ if ((SQL_NUMROWS($result_mem) > 0) && ($display)) { // Free result SQL_FREERESULT($result_mem); -// Add new paypout type +// Add new payout type if ($display === true) loadTemplate('admin_payout_add_new'); // [EOF] diff --git a/inc/modules/admin/what-config_wernis.php b/inc/modules/admin/what-config_wernis.php index db31390b5c..f7f0d0aa4a 100644 --- a/inc/modules/admin/what-config_wernis.php +++ b/inc/modules/admin/what-config_wernis.php @@ -39,7 +39,7 @@ // Some security stuff... if ((!defined('__SECURITY')) || (!isAdmin())) { die(); -} +} // END - if // Add description as navigation point addMenuDescription('admin', __FILE__); diff --git a/inc/modules/member/what-beg.php b/inc/modules/member/what-beg.php index 8e0ca1077e..940e272d4a 100644 --- a/inc/modules/member/what-beg.php +++ b/inc/modules/member/what-beg.php @@ -51,45 +51,19 @@ if ((!isExtensionActive('beg')) && (!isAdmin())) { return; } // END - if -// Get userid -$userid = getMemberId(); - -if (isExtensionActive('nickname')) { - // Load nickname - $data = 'nickname'; +// Prepare constants +if ((isExtensionActive('nickname')) && (getUserData('nickname') != '')) { + // Get nickname + $content['userid'] = getUserData('nickname'); } else { - // Load userid - $data = 'userid'; + // Get userid + $content['userid'] = getMemberId(); } -// Run SQL command -$result = SQL_QUERY_ESC("SELECT - `".$data."`, `beg_clicks` -FROM - `{?_MYSQL_PREFIX?}_user_data` -WHERE - `userid`=%s -LIMIT 1", array($userid), __FILE__, __LINE__); - -list($userid, $clicks) = SQL_FETCHROW($result); - -// Free result -SQL_FREERESULT($result); - -// Set user id when no nickname was found -$nickname = true; -if (empty($userid)) { $userid = getMemberId(); $nickname = false; } - -// Prepare constants -$content['userid'] = $userid; -$content['clicks'] = $clicks; -$content['points'] = translateComma(getConfig('beg_points')); -$content['points_max'] = translateComma(getConfig('beg_points_max')); -$content['timeout'] = createFancyTime(getConfig('beg_timeout')); // @TODO No more needed? define('__BEG_UID_TIMEOUT', createFancyTime(getConfig('beg_userid_timeout'))); // Load template -loadTemplate('member_' . substr(basename(__FILE__), 5, -4), false, $content); +loadTemplate('member_beg', false, $content); // [EOF] ?> diff --git a/inc/modules/member/what-doubler.php b/inc/modules/member/what-doubler.php index 9477d5413b..2d99333fba 100644 --- a/inc/modules/member/what-doubler.php +++ b/inc/modules/member/what-doubler.php @@ -52,11 +52,9 @@ if ((!isExtensionActive('doubler')) && (!isAdmin())) { } // END - if // Percent values etc. +// @TODO The '*100' is in the way to get moved into the template $content['charge'] = translateComma(getConfig('doubler_charge') * 100); $content['ref'] = translateComma(getConfig('doubler_ref') * 100); -$content['total'] = translateComma(getConfig('doubler_points')); -$content['min'] = translateComma(getConfig('doubler_min')); -$content['max'] = translateComma(getConfig('doubler_max')); // Default refid is the userid $content['userid'] = getMemberId(); diff --git a/inc/modules/member/what-html_mail.php b/inc/modules/member/what-html_mail.php index f5ef2e4995..25fff7aec6 100644 --- a/inc/modules/member/what-html_mail.php +++ b/inc/modules/member/what-html_mail.php @@ -58,12 +58,6 @@ if (isFormSent()) { array(postRequestElement('html'), getMemberId()), __FILE__, __LINE__); loadTemplate('admin_settings_saved', false, getMessage('MEMBER_SETTINGS_SAVED')); } else { - // Load template for changing settings - if (!fetchUserData(getMemberId())) { - // Something really bad happened - debug_report_bug('No user account ' . getMemberId() . ' found.'); - } // END - if - // Prepare it $content['html_y'] = ''; $content['html_n'] = ''; diff --git a/inc/modules/member/what-mydata.php b/inc/modules/member/what-mydata.php index 061743ca9a..3390b853bb 100644 --- a/inc/modules/member/what-mydata.php +++ b/inc/modules/member/what-mydata.php @@ -67,12 +67,6 @@ if (isPostRequestElementSet('notify')) $mode = 'notify'; // Switch off notificat switch ($mode) { case 'show': // Show his data - // Get user data - if (!fetchUserData(getMemberId())) { - // Something really bad happended - debug_report_bug('No user account ' . getMemberId() . ' found.'); - } // END - if - // Get line $content = merge_array($content, getUserDataArray()); @@ -83,7 +77,7 @@ switch ($mode) { // How far is last change on his profile away from now? if ((($content['last_update'] + getConfig('profile_lock')) > time()) && (!isAdmin()) && (getConfig('profile_lock') > 0)) { // You cannot change your account - $content['change'] = loadTemplate('admin_settings_saved', true, "
".sprintf(getMessage('MEMBER_PROFILE_LOCKED'), generateDateTime($content['last_update'] + getConfig('profile_lock'), 0))."
"); + $content['change'] = loadTemplate('admin_settings_saved', true, '
' . sprintf(getMessage('MEMBER_PROFILE_LOCKED'), generateDateTime($content['last_update'] + getConfig('profile_lock'), 0)) . '
'); } else { // He is allowed to change his profile $content['change'] = loadTemplate('member_mydata_button', true); @@ -140,7 +134,7 @@ LIMIT 1", $content['update_check'] = sprintf(getMessage('MEMBER_PROFILE_LOCKED'), generateDateTime($content['update_check'] + getConfig('profile_lock'), 0)); // You cannot change your account - loadTemplate('member_mydata_locked', false, $content); + loadTemplate('admin_settings_saved', false, $content['update_check']); } else { // He is allowed to change his profile foreach (array('gender_m','gender_f','gender_c') as $entry) { @@ -195,12 +189,6 @@ LIMIT 1", break; case 'save': // Save entered data - // Load old email / password - if (!fetchUserData(getMemberId())) { - // Something really bad happened - debug_report_bug('No user account ' . getMemberId() . ' found.'); - } // END - if - // Get line $content = merge_array($content, getUserDataArray()); @@ -210,8 +198,9 @@ LIMIT 1", // How far is last change on his profile away from now? if (($content['update_check'] > time()) && (!isAdmin()) && (getConfig('profile_lock') > 0)) { $content['update_check'] = generateDateTime($content['update_check'] + getConfig('profile_lock'), 0); + // You cannot change your account - loadTemplate('member_mydata_locked', false, $content); + loadTemplate('admin_settings_saved', false, $content['update_check']); } elseif ((!isEmailValid(postRequestElement('email'))) && (!isAdmin())) { // Invalid email address! loadTemplate('admin_settings_saved', false, getMessage('INVALID_EMAIL_ADDRESS_ENTERED')); diff --git a/inc/modules/member/what-payout.php b/inc/modules/member/what-payout.php index ba12785779..00e3bc4553 100644 --- a/inc/modules/member/what-payout.php +++ b/inc/modules/member/what-payout.php @@ -120,7 +120,7 @@ ORDER BY while ($content = SQL_FETCHARRAY($result_payouts)) { // Translate status $content['status'] = getMessage('PAYOUT_MEMBER_STATUS_'.strtoupper($content['status']).''); - $content['status'] = "
".$content['status']."
"; + $content['status'] = '
' . $content['status'] . '
'; // Nothing entered must be secured in member/what-payputs.php ! if ($content['allow'] == 'Y') { diff --git a/inc/modules/member/what-points.php b/inc/modules/member/what-points.php index 996b9dc1c7..523456832f 100644 --- a/inc/modules/member/what-points.php +++ b/inc/modules/member/what-points.php @@ -114,12 +114,6 @@ SQL_FREERESULT($result_depths); // Put rows to constant for the main template $content['rows'] = $OUT; -// Fetch user account -if (!fetchUserData(getMemberId())) { - // Something really bad happened - debug_report_bug('User account ' . getMemberId() . ' not found.'); -} // END - if - // Initialize variables $CONFIRMED = '---'; $SENT = '---'; $RECEIVED = '---'; @@ -145,7 +139,6 @@ if (isExtensionInstalledAndNewer('user', '0.1.2')) { if ($TLOCK == '0') $TLOCK = '0.00000'; // Remember several values in constants -$content['used'] = translateComma(getUserData('used_points')); $content['sum'] = translateComma($totalPoints - getUserData('used_points')); $content['tref'] = $TREF; $content['tlock'] = translateComma($TLOCK); @@ -198,7 +191,6 @@ if ((isExtensionInstalledAndNewer('bonus', '0.2.2')) && (isExtensionActive('bonu // Remeber values for the final template $content['receive'] = $RECEIVED; -$content['pay'] = getUserData('ref_payout'); $content['confirmed'] = $CONFIRMED; $content['sent'] = $SENT; diff --git a/inc/modules/member/what-primera.php b/inc/modules/member/what-primera.php index 2a1322dbee..63f4d1ec2c 100644 --- a/inc/modules/member/what-primera.php +++ b/inc/modules/member/what-primera.php @@ -69,12 +69,6 @@ if (!isGetRequestElementSet('mode')) { // Get referal id $content['refid'] = getConfig(('primera_refid')); - // Are there some entries? - if (fetchUserData(getMemberId())) { - // Fetch id - $content['primera_nickname'] = getUserData('primera_nickname'); - } // END - if - // Is there an id? if ((!empty($content['primera_nickname'])) && (!isGetRequestElementSet('mode'))) { // Then use an other "mode" @@ -129,17 +123,7 @@ if (getRequestElement('mode') == 'pay') { } // Add points to content array - $content['points'] = $points; - $content['min_points'] = translateComma(getConfig('primera_min_payout')); - - // Get Primera id - $content['primera_nickname'] = ''; - - // Do we have a user account? (should be!) - if (fetchUserData(getMemberId())) { - // Fetch id - $content['primera_nickname'] = getUserData('primera_nickname'); - } // END - if + $content['points'] = $points; } else { // Invalid mode! loadTemplate('admin_settings_saved', false, sprintf(getMessage('PRIMERA_MEMBER_MODE_INVALID'), getRequestElement('mode'))); diff --git a/inc/modules/member/what-refback.php b/inc/modules/member/what-refback.php index 9d1525d2de..c42e21d800 100644 --- a/inc/modules/member/what-refback.php +++ b/inc/modules/member/what-refback.php @@ -95,8 +95,6 @@ if ((isPostRequestElementSet('edit')) && (isPostRequestElementSet('id'))) { // Translate comma $content['refback'] = translateComma($content['refback']); - $content['min'] = translateComma(getConfig('refback_min_perc').".0"); - $content['max'] = translateComma(getConfig('refback_max_perc').".0"); // Load form for editing loadTemplate('member_refback_edit', false, $content); diff --git a/inc/modules/member/what-reflinks.php b/inc/modules/member/what-reflinks.php index 7a02cdecc2..6bc1bce1d5 100644 --- a/inc/modules/member/what-reflinks.php +++ b/inc/modules/member/what-reflinks.php @@ -46,14 +46,7 @@ if (!defined('__SECURITY')) { // Add description as navigation point addMenuDescription('member', __FILE__); -// Load current referal clicks -if (!fetchUserData(getMemberId())) { - // Something really bad happened - debug_report_bug('No user account ' . getMemberId() . ' found.'); -} // END - if - // Prepare some data -$content['ref_clicks'] = getUserData('ref_clicks'); $content['userid'] = getMemberId(); $content['nickname_content'] = ''; diff --git a/inc/modules/member/what-transfer.php b/inc/modules/member/what-transfer.php index 993a122bb3..b228e82dcd 100644 --- a/inc/modules/member/what-transfer.php +++ b/inc/modules/member/what-transfer.php @@ -51,12 +51,6 @@ if ((!isExtensionActive('transfer')) && (!isAdmin())) { return; } // END - if -// Load data -if (!fetchUserData(getMemberId())) { - // Something really bad happened - debug_report_bug('No user account ' . getMemberId() . ' found.'); -} // END - if - // Check for mode in GET $mode = ''; if (isGetRequestElementSet('mode')) $mode = getRequestElement('mode'); diff --git a/inc/modules/member/what-wernis.php b/inc/modules/member/what-wernis.php index 1409dccf16..657312bd5c 100644 --- a/inc/modules/member/what-wernis.php +++ b/inc/modules/member/what-wernis.php @@ -68,12 +68,6 @@ if ((!isGetRequestElementSet('mode')) || (getRequestElement('mode') == 'choose') $content['refid'] = getConfig(('wernis_refid')); $content['wernis_userid'] = '0'; - // Are there some entries? - if (fetchUserData(getMemberId())) { - // Fetch id - $content['wernis_userid'] = getUserData('wernis_userid'); - } // END - if - // Is there an id? if ((!empty($content['wernis_userid'])) && (!isGetRequestElementSet('mode'))) { // Then use an other "mode" @@ -150,36 +144,22 @@ if ((!isGetRequestElementSet('mode')) || (getRequestElement('mode') == 'choose') // Add points to content array $content['points'] = translateComma($points); - $content['min_points'] = translateComma(getConfig('wernis_min_payout')); - - // Add fees to array - WERNIS_ADD_FEES_TO_ARRAY($content); - // Init WDS66 userid - $content['wernis_userid'] = ''; - - // Are there some entries? - if (fetchUserData(getMemberId())) { - // Fetch id - $content['wernis_userid'] = getUserData('wernis_userid'); - } // END - if + // Get WDS66 username + $content['wernis_userid'] = getUserData('wernis_userid'); } elseif ((getRequestElement('mode') == 'withdraw') && (getConfig('wernis_withdraw_active') == 'Y')) { // Get total points for just displaying them $points = countSumTotalData(getMemberId(), 'user_points', 'points') - countSumTotalData(getMemberId(), 'user_data', 'used_points'); // Prepare data for the template $content['points'] = translateComma($points); - $content['min_points'] = translateComma(getConfig('wernis_min_withdraw')); $content['wernis_userid'] = ''; // Add fees to array WERNIS_ADD_FEES_TO_ARRAY($content); - // Get WDS66 id - if (fetchUserData(getMemberId())) { - // Fetch id - $content['wernis_userid'] = getUserData('wernis_userid'); - } // END - if + // Fetch id + $content['wernis_userid'] = getUserData('wernis_userid'); } else { // Invalid mode! loadTemplate('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_MODE_INVALID'), getRequestElement('mode'))); diff --git a/inc/reset/reset_100_bonus.php b/inc/reset/reset_100_bonus.php index 6bfb16c447..f2509c85c6 100644 --- a/inc/reset/reset_100_bonus.php +++ b/inc/reset/reset_100_bonus.php @@ -60,9 +60,6 @@ ORDER BY `userid` ASC", __FILE__, __LINE__); if (SQL_NUMROWS($result_bonus) > 0) { - // Remember stats bonus in constant - $content['points'] = translateComma(getConfig('bonus_stats')); - // We found some mail orders... while ($content = merge_array($content, SQL_FETCHARRAY($result_bonus))) { // Add points diff --git a/inc/reset/reset_birthday.php b/inc/reset/reset_birthday.php index 9836603297..fb4feb0b5e 100644 --- a/inc/reset/reset_birthday.php +++ b/inc/reset/reset_birthday.php @@ -86,7 +86,6 @@ if (SQL_NUMROWS($result_birthday) > 0) { if (getConfig('birthday_points') > 0) { // Add more entries to the array $content['age'] = $age; - $content['points'] = translateComma(getConfig('birthday_points')); $content['check'] = ''; // @TODO 4 is hard-coded here, should we move it out in config? diff --git a/templates/de/emails/beg/beg_en_notify.tpl b/templates/de/emails/beg/beg_en_notify.tpl index 668c29d866..81539ecb6f 100644 --- a/templates/de/emails/beg/beg_en_notify.tpl +++ b/templates/de/emails/beg/beg_en_notify.tpl @@ -10,11 +10,11 @@ Soeben haben wir von {?MAIN_TITLE?} eine Bettel-Rallye gestartet. Hier alle Infos zur Bettel-Rallye: ------------------------------ -Minimale {?POINTS?} pro erfolgreichem Betteln: $content[min_points] +Minimale {?POINTS?} pro erfolgreichem Betteln: {%config,translateComma=beg_points%} ------------------------------ -Maximale {?POINTS?} pro erfolgreichem Betteln: $content[min_points] +Maximale {?POINTS?} pro erfolgreichem Betteln: {%config,translateComma=beg_points_max%} ------------------------------ -Maximale Gewinner dieser Bettel-Rallye: $content[max_winner] +Maximale Gewinner dieser Bettel-Rallye: {%config,round=beg_ranks%} ------------------------------ IP-Sperre: $content[ip_locker] ------------------------------ diff --git a/templates/de/emails/member/member_birthday_confirm.tpl b/templates/de/emails/member/member_birthday_confirm.tpl index a485184ebf..141914660f 100644 --- a/templates/de/emails/member/member_birthday_confirm.tpl +++ b/templates/de/emails/member/member_birthday_confirm.tpl @@ -2,7 +2,7 @@ Hallo {%user,gender,translateGender=$userid%} {%user,surname=$userid%} {%user,fa Wir das Team von {?MAIN_TITLE?} wünschen Ihnen alles Gute und Gesundheit zu Ihrem $content[age]. Geburtstag! -Wenn Sie den folgenden Link anklicken, erhalten Sie $content[points] {?POINTS?} Ihrem Account sofort gutgeschrieben! +Wenn Sie den folgenden Link anklicken, erhalten Sie {%config,translateComma=birthday_points%} {?POINTS?} Ihrem Account sofort gutgeschrieben! ---------------------------------------------------------------------- {?URL?}/birthday_confirm.php?userid=$userid&check=$content[check] diff --git a/templates/de/emails/member/member_stats_bonus.tpl b/templates/de/emails/member/member_stats_bonus.tpl index d0898ba76d..577e9fa1ce 100644 --- a/templates/de/emails/member/member_stats_bonus.tpl +++ b/templates/de/emails/member/member_stats_bonus.tpl @@ -1,6 +1,6 @@ Hallo {%user,gender,translateGender=$userid%} {%user,surname=$userid%} {%user,family=$userid%}, -Sie haben soeben $content[points] {?POINTS?} auf Ihr Aktiv-Konto gutgeschrieben bekommen, da die folgende Werbebuchung 100% Klickrate erreicht hat: +Sie haben soeben {%config,translateComma=bonus_stats%} {?POINTS?} auf Ihr Aktiv-Konto gutgeschrieben bekommen, da die folgende Werbebuchung 100% Klickrate erreicht hat: ------------------------------ Ihre Mitglied-Id lautet: $userid diff --git a/templates/de/html/guest/guest_goto_top.tpl b/templates/de/html/guest/guest_goto_top.tpl index 8dc07a9484..9e3a2365d1 100644 --- a/templates/de/html/guest/guest_goto_top.tpl +++ b/templates/de/html/guest/guest_goto_top.tpl @@ -1,4 +1,5 @@ - {--TOP--} + +
{--TOP--}
+ diff --git a/templates/de/html/member/member_beg.tpl b/templates/de/html/member/member_beg.tpl index 38210876fa..a3a6813925 100644 --- a/templates/de/html/member/member_beg.tpl +++ b/templates/de/html/member/member_beg.tpl @@ -8,14 +8,14 @@ {--BEG_MEMBER_CLICKS_TOTAL--}:
- $content[clicks] + {%user,beg_clicks,translateComma%} -

{--BEG_MEMBER_EARN_1--} $content[points] - {?POINTS?} {--BEG_MEMBER_EARN_2--} $content[points_max] +

{--BEG_MEMBER_EARN_1--} {%config,translateComma=beg_points%} + {?POINTS?} {--BEG_MEMBER_EARN_2--} {%config,translateComma=beg_points_max%} {?POINTS?} {--BEG_MEMBER_EARN_3--}

-

{--BEG_MEMBER_TIMEOUT_1--} $content[timeout] +

{--BEG_MEMBER_TIMEOUT_1--} {%config,createFancyTime=beg_timeout%} {--BEG_MEMBER_TIMEOUT_2--}

{--BEG_MEMBER_HAVE_FUN--}

diff --git a/templates/de/html/member/member_doubler.tpl b/templates/de/html/member/member_doubler.tpl index bdda04953a..36bddd3d80 100644 --- a/templates/de/html/member/member_doubler.tpl +++ b/templates/de/html/member/member_doubler.tpl @@ -27,8 +27,8 @@
    -
  • {--DOUBLER_MINIMUM_IS--} $content[min] {?POINTS?} {--DOUBLER_MAXIMUM_IS--} $content[max] {?POINTS?}
  • -
  • {--DOUBLER_ALREADY_PAYED_1--} $content[total] {?POINTS?} {--DOUBLER_ALREADY_PAYED_2--}
  • +
  • {--DOUBLER_MINIMUM_IS--} {%config,translateComma=doubler_min%} {?POINTS?} {--DOUBLER_MAXIMUM_IS--} {%config,translateComma=doubler_max%} {?POINTS?}
  • +
  • {--DOUBLER_ALREADY_PAYED_1--} {%config,translateComma=doubler_points%} {?POINTS?} {--DOUBLER_ALREADY_PAYED_2--}
  • {--DOUBLER_POINTS_LEFT_1--} $content[left] {?POINTS?} {--DOUBLER_POINTS_LEFT_2--}
  • {--DOUBLER_USAGE_COUNTER_1--} {?doubler_counter?} {--DOUBLER_USAGE_COUNTER_2--}
  • $content[payout_time]
  • diff --git a/templates/de/html/member/member_goto_top.tpl b/templates/de/html/member/member_goto_top.tpl index 8dc07a9484..9e3a2365d1 100644 --- a/templates/de/html/member/member_goto_top.tpl +++ b/templates/de/html/member/member_goto_top.tpl @@ -1,4 +1,5 @@ - {--TOP--} + + + diff --git a/templates/de/html/member/member_holiday_form.tpl b/templates/de/html/member/member_holiday_form.tpl index 4aabcde209..c396c1a0c2 100644 --- a/templates/de/html/member/member_holiday_form.tpl +++ b/templates/de/html/member/member_holiday_form.tpl @@ -24,7 +24,8 @@ - {--HOLIDAY_COMMENTS--}:
    + + {--HOLIDAY_COMMENTS--}:
    diff --git a/templates/de/html/member/member_mydata_edit.tpl b/templates/de/html/member/member_mydata_edit.tpl index 0362a228c4..77ca7cebce 100644 --- a/templates/de/html/member/member_mydata_edit.tpl +++ b/templates/de/html/member/member_mydata_edit.tpl @@ -1,124 +1,78 @@ +
    - +
    - - - - - - - - - - - + - - - - - + - - - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - + - + + - + - + - - - - - - - - - - - - - + - + + - +
     
     {--YOUR_LOGIN--}: $content[userid] 
      + {--YOUR_LOGIN--}: $content[userid] +
    {--GENDER--}: 
      + +
    {--SURNAME--}, {--FAMILY_NAME--}: 
     
    {--STREET_NR--}: 
     
    {--COUNTRY--}, {--ZIP--}, {--CITY--}: $content[country]    -
      + $content[country] + + +
    {--EMAIL_ADDRESS--}: 
     
    {--BIRTHDAY--}: $content[dob]
     
    $content[max_receive_list]
     
      + +
    {--MYDATA_NOTE--}{--BIRTHDAY--}:$content[dob]
     $content[max_receive_list]
      + {--MYDATA_NOTE--} +
    {--PASS_1--}: 
     
    {--PASS_2--}: 
      + +
     {--PASS_2--}: + +
     
    +
    diff --git a/templates/de/html/member/member_mydata_locked.tpl b/templates/de/html/member/member_mydata_locked.tpl index b42a0533a9..11f5d85d80 100644 --- a/templates/de/html/member/member_mydata_locked.tpl +++ b/templates/de/html/member/member_mydata_locked.tpl @@ -1,11 +1 @@ - - - - - - - - - - -
     
    $content[update_check]
     
    \ No newline at end of file + diff --git a/templates/de/html/member/member_points.tpl b/templates/de/html/member/member_points.tpl index 4c48d7bb7f..1b5c20b08e 100644 --- a/templates/de/html/member/member_points.tpl +++ b/templates/de/html/member/member_points.tpl @@ -1,99 +1,53 @@ - +
    +
    - - - - - - - - - - + + + $content[rows] - - - - - - - - + + + - - - - - - + - - - - - + - - - - + + $content[special_rows] - - - - - - - - - - - + + - - - - - - - + + - - - - - - - + + - - - - - - - + + - - -
     
    {--REF_LEVEL--}{?POINTS?}{--REFERALS--}{--REF_LEVEL--}{?POINTS?}{--REFERALS--}
     
      {--POINTS_USED--}   $content[used] {?POINTS?}   {--POINTS_USED--} {%user,used_points,translateComma%} {?POINTS?} 
     
      {--POINTS_SUM--}  -   $content[sum] {?POINTS?} +  {--POINTS_SUM--} +  $content[sum] {?POINTS?}    $content[tref]
     $content[tref]
      {--POINTS_LOCKED--}   $content[tlock] {?POINTS?}  {--POINTS_LOCKED--} $content[tlock] {?POINTS?}  
     
    +
    {--CLICK_STATISTICS--}
     
      {--RECEIVED_MAILS--}:   $content[receive]  {--RECEIVED_MAILS--}: $content[receive]  
     
      {--UNCONFIRMED_LOCKED--}:   $content[pay]  {--UNCONFIRMED_LOCKED--}: {%user,ref_payout%}  
     
      {--CONFIRMED_MAILS--}:   $content[confirmed]  {--CONFIRMED_MAILS--}: $content[confirmed]  
     
      {--SENT_MAILS--}:   $content[sent]  {--SENT_MAILS--}: $content[sent]  
     
    +
diff --git a/templates/de/html/member/member_points_bonus_disabled.tpl b/templates/de/html/member/member_points_bonus_disabled.tpl index 67a25a733e..59effa6901 100644 --- a/templates/de/html/member/member_points_bonus_disabled.tpl +++ b/templates/de/html/member/member_points_bonus_disabled.tpl @@ -1,8 +1,5 @@ -   - - - + {--BONUS_POINTS_DISABLED--} diff --git a/templates/de/html/member/member_points_bonus_rows.tpl b/templates/de/html/member/member_points_bonus_rows.tpl index c5a4d617bb..ca0af4b6ad 100644 --- a/templates/de/html/member/member_points_bonus_rows.tpl +++ b/templates/de/html/member/member_points_bonus_rows.tpl @@ -1,76 +1,40 @@ -   - - - {--BONUS_POINTS_TITLE--} + + {--BONUS_POINTS_TITLE--} -   - - - -
{--BONUS_LOGIN_TURBO_NOTE--}
+ +
{--BONUS_LOGIN_TURBO_NOTE--}
-   - - -   {--BONUS_LOGIN_TOTAL--} -   -   $content[login] {?POINTS?} -   +  {--BONUS_LOGIN_TOTAL--} +  $content[login] {?POINTS?}   -   - - -   {--BONUS_TURBO_TOTAL--} -   -   $content[turbo] {?POINTS?} -   +  {--BONUS_TURBO_TOTAL--} +  $content[turbo] {?POINTS?}   -   - - -   {--BONUS_REF_TOTAL--} -   -   $content[ref] {?POINTS?} -   -   - - -   - - -   {--BONUS_ORDER_TOTAL--} -   -   $content[order] {?POINTS?} -   +  {--BONUS_REF_TOTAL--} +  $content[ref] {?POINTS?}   -   - - -   {--BONUS_STATS_TOTAL--} -   -   $content[stats] {?POINTS?} -   +  {--BONUS_ORDER_TOTAL--} +  $content[order] {?POINTS?}   -   +  {--BONUS_STATS_TOTAL--} +  $content[stats] {?POINTS?} +   -   {--BONUS_TOTAL--} -   -   $content[ttotal] - {?POINTS?} -   +  {--BONUS_TOTAL--} +  $content[ttotal] {?POINTS?}   diff --git a/templates/de/html/member/member_points_row.tpl b/templates/de/html/member/member_points_row.tpl index 7c88d0f8ab..b0d4eb0772 100644 --- a/templates/de/html/member/member_points_row.tpl +++ b/templates/de/html/member/member_points_row.tpl @@ -1,10 +1,5 @@ -   - - -   $content[level] {--REF_LEVEL--} ($content[percents]%) -   -   $content[points] {?POINTS?} -   -   $content[refs] +  $content[level] {--REF_LEVEL--} ($content[percents]%) +  $content[points] {?POINTS?} + $content[refs] diff --git a/templates/de/html/member/member_points_upgrade.tpl b/templates/de/html/member/member_points_upgrade.tpl index fd32c4e237..7e3cf2e277 100644 --- a/templates/de/html/member/member_points_upgrade.tpl +++ b/templates/de/html/member/member_points_upgrade.tpl @@ -1,10 +1,5 @@ -   - - - - {--BONUS_EXTENSION_UPGRADE_1--} - v0.2.2 - {--BONUS_EXTENSION_UPGRADE_2--} + + {--BONUS_EXTENSION_UPGRADE_1--}v0.2.2{--BONUS_EXTENSION_UPGRADE_2--} diff --git a/templates/de/html/member/member_primera_mode_pay.tpl b/templates/de/html/member/member_primera_mode_pay.tpl index f59e48972f..5093d083d6 100644 --- a/templates/de/html/member/member_primera_mode_pay.tpl +++ b/templates/de/html/member/member_primera_mode_pay.tpl @@ -13,15 +13,12 @@ {--PRIMERA_MEMBER_PAYOUT_MIN_POINTS--}   - $content[min_points] Primera - - -   + {%config,translateComma=primera_min_payout%} Primera {--PRIMERA_MEMBER_NICKNAME--}   - + {--PRIMERA_MEMBER_PASSWORD--} @@ -33,9 +30,6 @@   - -   - diff --git a/templates/de/html/member/member_refback_edit.tpl b/templates/de/html/member/member_refback_edit.tpl index 67acd7919c..2b4e1b3da6 100644 --- a/templates/de/html/member/member_refback_edit.tpl +++ b/templates/de/html/member/member_refback_edit.tpl @@ -1,29 +1,23 @@ +
- - - - - - - - - - - -
- {--MEMBER_REFBACK_EDIT_TITLE--}
- {--MEMBER_REFBACK_REFID--}: $content[refid] -
- {--MEMBER_REFBACK_PERCENTS--}: - - % -
+
+
+ {--MEMBER_REFBACK_EDIT_TITLE--}
+ {--MEMBER_REFBACK_REFID--}: $content[refid] +
+
+ {--MEMBER_REFBACK_PERCENTS--}: + % +
+ +
+
- {--MEMBER_REFBACK_MIN_MAX_NOTE_1--}$content[min]{--MEMBER_REFBACK_MIN_MAX_NOTE_2--}$content[max]{--MEMBER_REFBACK_MIN_MAX_NOTE_3--} + {--MEMBER_REFBACK_MIN_MAX_NOTE_1--}{%config,translateComma=refback_min_perc%}{--MEMBER_REFBACK_MIN_MAX_NOTE_2--}{%config,translateComma=refback_max_perc%}{--MEMBER_REFBACK_MIN_MAX_NOTE_3--}
diff --git a/templates/de/html/member/member_reflink.tpl b/templates/de/html/member/member_reflink.tpl index a582d3df87..d63d90a095 100644 --- a/templates/de/html/member/member_reflink.tpl +++ b/templates/de/html/member/member_reflink.tpl @@ -6,7 +6,7 @@ $content[nickname_content]
- {--YOUR_REFCLICKS--}: $content[ref_clicks] {--CLICKS--} + {--YOUR_REFCLICKS--}: {%user,ref_clicks,translateComma%} {--CLICKS--}
$content[refbanner_content] diff --git a/templates/de/html/member/member_wernis_mode_payout.tpl b/templates/de/html/member/member_wernis_mode_payout.tpl index bd27fee3b0..2818a23db1 100644 --- a/templates/de/html/member/member_wernis_mode_payout.tpl +++ b/templates/de/html/member/member_wernis_mode_payout.tpl @@ -12,7 +12,7 @@ {--WERNIS_MEMBER_PAYOUT_MIN_POINTS--}   - $content[min_points] Wernis + {%config,translateComma=wernis_min_payout%} Wernis   @@ -49,9 +49,9 @@
- Die Umrechnung von {?POINTS?} in Wernis enspricht derzeit $content[payout_factor]:1. + Die Umrechnung von {?POINTS?} in Wernis enspricht derzeit {%config,translateComma=wernis_payout_factor%}:1. Das auszahlungsfähige {?POINTS?}-Guthaben ist entweder um eine - prozentuale Gebühr von $content[payout_fee_percent]% - oder um einen fixen Betrag von $content[payout_fee_fix] {?POINTS?} + prozentuale Gebühr von {%config,translateComma=wernis_payout_fee_percent%}% + oder um einen fixen Betrag von {%config,translateComma=wernis_payout_fee_fix%} {?POINTS?} bereits reduziert.
diff --git a/templates/de/html/member/member_wernis_mode_withdraw.tpl b/templates/de/html/member/member_wernis_mode_withdraw.tpl index 3f9e66be2d..bf92071fc2 100644 --- a/templates/de/html/member/member_wernis_mode_withdraw.tpl +++ b/templates/de/html/member/member_wernis_mode_withdraw.tpl @@ -13,7 +13,7 @@ {--WERNIS_MEMBER_WITHDRAW_MIN_POINTS--}   - $content[min_points] Wernis + {%config,translateComma=wernis_min_withdraw%} Wernis   @@ -43,9 +43,8 @@ -
-{--WERNIS_MEMBER_WITHDRAW_NOTE--}
+ {--WERNIS_MEMBER_WITHDRAW_NOTE--}
-- 2.39.5