From f55a18dbd4f2312a8812fb3feb3296b350ba269b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Sat, 24 Jul 2010 01:32:28 +0000 Subject: [PATCH] More rewrites/fixes (not all is fixed) for ext-sponsor --- DOCS/TODOs.txt | 3 + inc/extensions-functions.php | 10 +-- inc/extensions/ext-sponsor.php | 2 +- inc/language/sponsor_de.php | 2 +- inc/libs/sponsor_functions.php | 55 ++++++------- inc/modules/guest/what-sponsor_login.php | 13 +++- inc/modules/guest/what-sponsor_reg.php | 78 ++++++++++--------- inc/modules/sponsor.php | 2 +- inc/modules/sponsor/.php | 4 +- inc/modules/sponsor/account.php | 12 +-- inc/modules/sponsor/settings.php | 10 +-- inc/modules/sponsor/welcome.php | 4 +- .../admin/admin_sponsor_change_data.tpl | 2 +- .../admin/admin_sponsor_change_email.tpl | 2 +- .../de/emails/admin/admin_sponsor_edit.tpl | 6 +- .../de/emails/admin/admin_sponsor_pending.tpl | 4 +- templates/de/emails/del_sponsor.tpl | 4 +- templates/de/emails/lock_sponsor.tpl | 4 +- .../de/emails/sponsor/sponsor_activate.tpl | 2 +- .../de/emails/sponsor/sponsor_add_points.tpl | 2 +- .../de/emails/sponsor/sponsor_change_data.tpl | 18 ++--- .../de/emails/sponsor/sponsor_confirm.tpl | 2 +- templates/de/emails/sponsor/sponsor_email.tpl | 2 +- templates/de/emails/sponsor/sponsor_lost.tpl | 2 +- .../de/emails/sponsor/sponsor_pending.tpl | 24 +++--- .../de/emails/sponsor/sponsor_ref_notify.tpl | 2 +- .../de/emails/sponsor/sponsor_settings.tpl | 2 +- .../de/emails/sponsor/sponsor_sub_points.tpl | 2 +- .../de/emails/sponsor/sponsor_unlock.tpl | 2 +- .../de/emails/sponsor/sponsor_unlocked.tpl | 2 +- templates/de/html/guest/guest_menu_whats.tpl | 9 +-- .../de/html/member/member_menu_whats.tpl | 9 +-- .../de/html/sponsor/sponsor_account_form.tpl | 18 ++--- templates/de/html/sponsor/sponsor_action.tpl | 4 +- templates/de/html/sponsor/sponsor_header.tpl | 2 +- templates/de/html/sponsor/sponsor_welcome.tpl | 6 +- templates/de/html/sponsor/sponsor_what.tpl | 6 +- theme/business/css/general.css | 3 +- theme/business/css/sponsor.css | 10 ++- theme/default/css/general.css | 3 +- theme/default/css/sponsor.css | 10 ++- theme/desert/css/sponsor.css | 17 ++-- theme/org/css/sponsor.css | 21 +++-- 43 files changed, 200 insertions(+), 197 deletions(-) diff --git a/DOCS/TODOs.txt b/DOCS/TODOs.txt index 4ad4a8c405..4156cc1acf 100644 --- a/DOCS/TODOs.txt +++ b/DOCS/TODOs.txt @@ -150,6 +150,7 @@ ./inc/modules/guest/what-mediadata.php:183:// @TODO Rewrite all these if-blocks to filters ./inc/modules/guest/what-mediadata.php:70: // @TODO Find a better formular than this one ./inc/modules/guest/what-rallyes.php:91: // @TODO Reactivate this: $content['admin'] = '' . $login . ''; +./inc/modules/guest/what-sponsor_reg.php:297: // @TODO Maybe a default referal id? ./inc/modules/guest/what-stats.php:116: // @TODO This can be somehow rewritten ./inc/modules/guest/what-stats.php:76:// @TODO This can be rewritten in a dynamic include ./inc/modules/member/what-beg.php:56:// @TODO Can't this be moved into EL? @@ -263,6 +264,8 @@ ./templates/de/html/admin/admin_refbanner_edit.tpl:1: ./templates/de/html/admin/admin_refbanner_row.tpl:1: ./templates/de/html/admin/admin_refbanner.tpl:1: +./templates/de/html/guest/guest_menu_whats.tpl:1: +./templates/de/html/member/member_menu_whats.tpl:1: ### ### template-warnings.log follows: ### ### Warning: Not parsing JavaScript templates/de/html/js/js_order_send.tpl. Warning: Not parsing JavaScript templates/de/html/js/js_cookies_disabled.tpl. diff --git a/inc/extensions-functions.php b/inc/extensions-functions.php index e63855da65..3706a5cb4f 100644 --- a/inc/extensions-functions.php +++ b/inc/extensions-functions.php @@ -1467,7 +1467,7 @@ function initExtensionSqls ($force = false) { // Adds SQLs to the SQLs array but "assigns" it with current extension name function addExtensionSql ($sql) { // Add it - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'ext_name=' . getCurrentExtensionName() . ',ext_version=' . getCurrentExtensionVersion() . ',sql=' . $sql); + /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'ext_name=' . getCurrentExtensionName() . ',ext_version=' . getCurrentExtensionVersion() . ',sql=' . $sql); $GLOBALS['ext_sqls'][getCurrentExtensionName()][getCurrentExtensionVersion()][] = $sql; } @@ -1770,7 +1770,7 @@ function addAdminMenuSql ($action, $what, $title, $descr, $sort) { addExtensionSql($sql); } elseif (isDebugModeEnabled()) { // Double menus should be located and fixed! - logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double admin menu action=%s, what=%s detected.", $action, $what)); + logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double admin menu action=%s,what=%s,title=%s detected.", $action, $what, $title)); } } @@ -1804,7 +1804,7 @@ function addGuestMenuSql ($action, $what, $title, $visible, $locked, $sort) { addExtensionSql($sql); } elseif (isDebugModeEnabled()) { // Double menus should be located and fixed! - logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double guest menu action=%s, what=%s detected.", $action, $what)); + logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double guest menu action=%s,what=%s,title=%s,active=%s detected.", $action, $what, $title, $active)); } } @@ -1838,7 +1838,7 @@ function addMemberMenuSql ($action, $what, $title, $visible, $locked, $sort) { addExtensionSql($sql); } elseif (isDebugModeEnabled()) { // Double menus should be located and fixed! - logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double member menu action=%s, what=%s detected.", $action, $what)); + logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double member menu action=%s,what=%s,title=%s,visivle=%s,locked=%s detected.", $action, $what, $title, $visible, $locked)); } } @@ -1870,7 +1870,7 @@ function addSponsorMenuSql ($action, $what, $title, $active, $sort) { addExtensionSql($sql); } elseif (isDebugModeEnabled()) { // Double menus should be located and fixed! - logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double sponsor menu action=%s, what=%s detected.", $action, $what)); + logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double sponsor menu action=%s,what=%s,title=%s,active=%s detected.", $action, $what, $title, $active)); } } diff --git a/inc/extensions/ext-sponsor.php b/inc/extensions/ext-sponsor.php index d0e0cf08a5..581cf90c5a 100644 --- a/inc/extensions/ext-sponsor.php +++ b/inc/extensions/ext-sponsor.php @@ -392,7 +392,7 @@ PRIMARY KEY (`id`) addExtensionSql('DROP TABLE IF EXISTS `{?_MYSQL_PREFIX?}_sponsor_display_data`'); addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `action`='sponsor' OR `what` IN('repr_sponsor','sponsor_medit','sponsor_madd')"); addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_guest_menu` WHERE `action`='sponsor'"); - addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_member_menu` WHERE `what`='sponsor'"); + addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_member_menu` WHERE `what` IN('sponsor_list','sponsor_reg')"); break; case 'activate': // Do stuff when admin activates this extension diff --git a/inc/language/sponsor_de.php b/inc/language/sponsor_de.php index ffeceaf318..fe7a233b78 100644 --- a/inc/language/sponsor_de.php +++ b/inc/language/sponsor_de.php @@ -251,7 +251,7 @@ addMessages(array( 'SPONSOR_UNKNOWN_STATUS' => "Bei der Anmeldung wurde ein unbekannter Rückgabewert %s erkannt. Bitte melden Sie dies dem Betreiber dieses {?mt_word2?}!
Vielen Dank.", 'SPONSOR_EMAIL_404' => "Bei der Anmeldung ist uns ein Fehler unterlaufen: Ihr Sponsor-Account mit der EMail-Adresse %s wurde nicht gefunden.", 'SPONSOR_ACCOUNT_PENDING_FAILED' => "Bei der Umschaltung Ihres Sponorenaccounts auf Wartend trat ein unerwarteter Fehler auf.", - 'SPONSOR_ACCOUNT_404' => "Sponsorenaccount %s nicht gefunden.", + 'SPONSOR_ACCOUNT_404' => "Das von Ihnen angegebene Sponsorenaccount %s konnte nicht gefunden werden.", 'SPONSOR_ACCOUNT_FAILED' => "Sponsorenaccount konnte nicht geladen werden: %s", 'SPONSOR_ACCOUNT_EMAIL_FAILED' => "Konnten Sponsorenaccount nicht freigeben! Bitte benachrichtigen Sie den Support.", diff --git a/inc/libs/sponsor_functions.php b/inc/libs/sponsor_functions.php index 46e4a13b0f..37c66b190c 100644 --- a/inc/libs/sponsor_functions.php +++ b/inc/libs/sponsor_functions.php @@ -250,29 +250,15 @@ function isSponsorRegisteredWithEmail ($email) { // Wether the current user is a sponsor function isSponsor () { - // Failed... + // Failed is default $ret = false; - if ((isSessionVariableSet('sponsor_id')) && (isSessionVariableSet('sponsorpass'))) { - // Check cookies against database records... - $result = SQL_QUERY_ESC("SELECT - `id` -FROM - `{?_MYSQL_PREFIX?}_sponsor_data` -WHERE - `id`=%s AND `password`='%s' AND `status`='CONFIRMED' -LIMIT 1", - array( - bigintval(getSession('sponsor_id')), - getSession('sponsorpass') - ), __FUNCTION__, __LINE__); - if (SQL_NUMROWS($result) == 1) { - // All is fine - $ret = true; - } // END - if - // Free memory - SQL_FREERESULT($result); - } // END - if + // Determine it + $ret = ( + (isSessionVariableSet('sponsor_id')) && + (isSessionVariableSet('sponsorpass')) && + (fetchSponsorData(getSession('sponsor_id'))) + ); // Return status return $ret; @@ -331,10 +317,7 @@ ORDER BY } // Prepare data for the main template - $content = array( - 'title' => $content['main_title'], - 'menu' => $SUB - ); + $content['menu'] = $SUB; // Load menu template $OUT .= loadTemplate('sponsor_action', true, $content); @@ -360,18 +343,21 @@ ORDER BY // function addSponsorContent ($what) { - $OUT = ''; + // Init sponsor content + $GLOBALS['sponsor_output'] = ''; + + // Generate IFN (Include FileName) $INC = sprintf("inc/modules/sponsor/%s.php", $what); if (isIncludeReadable($INC)) { - // Every sponsor action will output nothing directly. It will be written into $OUT! + // Every sponsor action will output nothing directly. It will be written into $GLOBALS['sponsor_output']! loadIncludeOnce($INC); } else { // File not found! - $OUT .= loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_CONTENT_404', $what)); + $GLOBALS['sponsor_output'] .= loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_CONTENT_404', $what)); } // Return content - return $OUT; + return $GLOBALS['sponsor_output']; } // @@ -397,7 +383,7 @@ LIMIT 1", // This update went fine? $login = (SQL_AFFECTEDROWS() == 1); - } + } // END - if // Return status return $login; @@ -844,5 +830,14 @@ function getSponsorData ($column) { return $GLOBALS['sponsor_data'][getCurrentSponsorId()][$column]; } +// Determines the country of the given sponsor id +function determineSponsorCountry ($sponsor_id) { + // Then handle it over + $country = getSponsorData('country'); + + // Return it + return $country; +} + // [EOF] ?> diff --git a/inc/modules/guest/what-sponsor_login.php b/inc/modules/guest/what-sponsor_login.php index 54fa6cd0d4..bdcd447680 100644 --- a/inc/modules/guest/what-sponsor_login.php +++ b/inc/modules/guest/what-sponsor_login.php @@ -70,7 +70,10 @@ if (isGetRequestParameterSet('hash')) { FROM `{?_MYSQL_PREFIX?}_sponsor_data` WHERE - `hash='%s' AND (`status`='UNCONFIRMED' OR `status`='EMAIL') + `hash`='%s' AND ( + `status`='UNCONFIRMED' OR + `status`='EMAIL' + ) LIMIT 1", array(getRequestParameter('hash')), __FILE__, __LINE__); if (SQL_NUMROWS($result) == 1) { // Sponsor found, load his data... @@ -82,10 +85,11 @@ LIMIT 1", array(getRequestParameter('hash')), __FILE__, __LINE__); SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_sponsor_data` SET - `status`='PENDING' + `status`='PENDING', + `hash`=NULL WHERE `id`=%s AND - hash='%s' AND + `hash`='%s' AND `status`='UNCONFIRMED' LIMIT 1", array( @@ -113,7 +117,8 @@ LIMIT 1", SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_sponsor_data` SET - `status`='CONFIRMED' + `status`='CONFIRMED', + `hash`=NULL WHERE `id`=%s AND `hash`='%s' AND diff --git a/inc/modules/guest/what-sponsor_reg.php b/inc/modules/guest/what-sponsor_reg.php index 8c9f367acc..75af8b376f 100644 --- a/inc/modules/guest/what-sponsor_reg.php +++ b/inc/modules/guest/what-sponsor_reg.php @@ -40,7 +40,7 @@ // Some security stuff... if (!defined('__SECURITY')) { die(); -} +} // END - if // Add description as navigation point addMenuDescription('guest', __FILE__); @@ -51,7 +51,7 @@ if ((!isExtensionActive('sponsor'))) { } // END - if // Create array for form errors (= missing data) -$FORM_ERRORS = array(); +$formErrors = array(); if (isFormSent()) { // @@ -60,17 +60,17 @@ if (isFormSent()) { // 1. Salutation / Surname / family name if (!isPostRequestParameterSet('gender')) { // Surname is empty - $FORM_ERRORS[] = '{--SPONSOR_NO_GENDER_SELECTED--}'; + $formErrors[] = '{--SPONSOR_NO_GENDER_SELECTED--}'; } // END - if if (!isPostRequestParameterSet('surname')) { // Surname is empty - $FORM_ERRORS[] = '{--SPONSOR_SURNAME_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_SURNAME_IS_EMPTY--}'; } // END - if if (!isPostRequestParameterSet('family')) { // Surname is empty - $FORM_ERRORS[] = '{--SPONSOR_FAMILY_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_FAMILY_IS_EMPTY--}'; } // END - if // 2. Company name @@ -78,128 +78,128 @@ if (isFormSent()) { if (((!isPostRequestParameterSet('company')) && ((isPostRequestParameterSet('tax_ident')) || (isPostRequestParameterSet('position')))) || ((isPostRequestParameterSet('company')) && (!isPostRequestParameterSet('tax_ident')))) { if (!isPostRequestParameterSet('company')) { // Company name is empty - $FORM_ERRORS[] = '{--SPONSOR_COMPANY_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_COMPANY_IS_EMPTY--}'; } elseif (!isPostRequestParameterSet('tax_ident')) { // Tax ident number name is empty - $FORM_ERRORS[] = '{--SPONSOR_TAX_IDENT_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_TAX_IDENT_IS_EMPTY--}'; } if (!isPostRequestParameterSet('position')) { // Not fatal but not nice: position in company is empty - $FORM_ERRORS[] = '{--SPONSOR_POSITION_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_POSITION_IS_EMPTY--}'; } // END - if } // END - if // 3. Street and number if (!isPostRequestParameterSet('street_nr1')) { // Street name and house number are empty - $FORM_ERRORS[] = '{--SPONSOR_STREET_NR1_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_STREET_NR1_IS_EMPTY--}'; } elseif ((isPostRequestParameterSet('street_nr2')) && (!isPostRequestParameterSet('street_nr1'))) { // 1st line for street is empty, but 2nd line not - $FORM_ERRORS[] = '{--SPONSOR_STREET_NR1_IS_EMPTY_2_NOT--}'; + $formErrors[] = '{--SPONSOR_STREET_NR1_IS_EMPTY_2_NOT--}'; } // 4. Country code if (!isPostRequestParameterSet('country')) { // Country code is empty - $FORM_ERRORS[] = '{--kSPONSOR_COUNTRY_IS_EMPTY--}'; + $formErrors[] = '{--kSPONSOR_COUNTRY_IS_EMPTY--}'; } elseif (strlen(postRequestParameter('country')) != 2) { // Country code is invalid - $FORM_ERRORS[] = '{--SPONSOR_COUNTRY_IS_INVALID--}'; + $formErrors[] = '{--SPONSOR_COUNTRY_IS_INVALID--}'; } // 3. ZIP code if (!isPostRequestParameterSet('zip')) { // ZIP code is empty - $FORM_ERRORS[] = '{--SPONSOR_ZIP_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_ZIP_IS_EMPTY--}'; } elseif (bigintval(postRequestParameter('zip')) != postRequestParameter('zip')) { // ZIP is invalid - $FORM_ERRORS[] = '{--SPONSOR_ZIP_IS_INVALID--}'; + $formErrors[] = '{--SPONSOR_ZIP_IS_INVALID--}'; setPostRequestParameter('zip', ''); } // 4. City if (!isPostRequestParameterSet('city')) { // City is empty - $FORM_ERRORS[] = '{--SPONSOR_CITY_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_CITY_IS_EMPTY--}'; } // END - if // 5. Phone number if (!isPostRequestParameterSet('phone')) { // City is empty - $FORM_ERRORS[] = '{--SPONSOR_PHONE_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_PHONE_IS_EMPTY--}'; } // END - if // 6. Homepage URL if (!isPostRequestParameterSet('url')) { // Homepage URL is empty - $FORM_ERRORS[] = '{--SPONSOR_URL_IS_EMPTY--}'; + $formErrors[] = '{--SPONSOR_URL_IS_EMPTY--}'; } elseif (!isUrlValid(postRequestParameter('url'))) { // Homepage URL is invalid - $FORM_ERRORS[] = '{--SPONSOR_URL_IS_INVALID--}'; + $formErrors[] = '{--SPONSOR_URL_IS_INVALID--}'; setPostRequestParameter('url', ''); } // 7. Light validation of email address if ((!isPostRequestParameterSet('email')) || (postRequestParameter('email') == '@')) { // Email is invalid/empty - $FORM_ERRORS[] = '{--SPONSOR_EMAIL_IS_INVALID--}'; + $formErrors[] = '{--SPONSOR_EMAIL_IS_INVALID--}'; } elseif (isSponsorRegisteredWithEmail(postRequestParameter('email'))) { // Email already found in database! - $FORM_ERRORS[] = '{--SPONSOR_EMAIL_IS_ALREADY_REGISTERED--}'; + $formErrors[] = '{--SPONSOR_EMAIL_IS_ALREADY_REGISTERED--}'; setPostRequestParameter('email', ''); } // 8. Pay type selected? if (!isPostRequestParameterSet('pay_type')) { // Not pay type selected - $FORM_ERRORS[] = '{--SPONSOR_NO_PAYTYPE_SELECTED--}'; + $formErrors[] = '{--SPONSOR_NO_PAYTYPE_SELECTED--}'; } // END - if // 9. Interval of mails if (!isPostRequestParameterSet('warning_interval')) { // No warning interval selected - $FORM_ERRORS[] = '{--SPONSOR_NO_WARNING_INTERVAL_SELECTED--}'; + $formErrors[] = '{--SPONSOR_NO_WARNING_INTERVAL_SELECTED--}'; } // END - if // 10. Mail notifications disabled/enabled if (!isPostRequestParameterSet('receive_warnings')) { // Option not selected! - $FORM_ERRORS[] = '{--SPONSOR_NO_RECEIVE_WARNINGS_SELECTED--}'; + $formErrors[] = '{--SPONSOR_NO_RECEIVE_WARNINGS_SELECTED--}'; } // END - if // Did he enter his password twice? if (((!isPostRequestParameterSet('pass1')) || (!isPostRequestParameterSet('pass2'))) || ((postRequestParameter('pass1') != postRequestParameter('pass2')) && (isPostRequestParameterSet('pass1')) && (isPostRequestParameterSet('pass2')))) { if ((postRequestParameter('pass1') != postRequestParameter('pass2')) && (isPostRequestParameterSet('pass1')) && (isPostRequestParameterSet('pass2'))) { // Passwords missmatch - $FORM_ERRORS[] = '{--SPONSOR_PASSWORDS_MISMATCH--}'; + $formErrors[] = '{--SPONSOR_PASSWORDS_MISMATCH--}'; } else { if (!isPostRequestParameterSet('pass1')) { // Password 1 is empty - $FORM_ERRORS[] = '{--SPONSOR_PASSWORD1_EMPTY--}'; + $formErrors[] = '{--SPONSOR_PASSWORD1_EMPTY--}'; } if (!isPostRequestParameterSet('pass2')) { // Password 2 is empty - $FORM_ERRORS[] = '{--SPONSOR_PASSWORD2_EMPTY--}'; + $formErrors[] = '{--SPONSOR_PASSWORD2_EMPTY--}'; } } } elseif (strlen(postRequestParameter('pass1')) < getConfig('pass_len')) { // Password is to short! - $FORM_ERRORS[] = '{--SPONSOR_PASSWORD_TOO_SHORT--}'; + $formErrors[] = '{--SPONSOR_PASSWORD_TOO_SHORT--}'; } // Check if he has accepted the terms&conditions if (!isPostRequestParameterSet('terms')) { // Homepage URL is empty - $FORM_ERRORS[] = '{--SPONSOR_TERMS_NOT_ACCEPTED--}'; + $formErrors[] = '{--SPONSOR_TERMS_NOT_ACCEPTED--}'; } // END - if // If there is something wrong/missing stop registration - if (count($FORM_ERRORS) > 0) unsetPostRequestParameter('ok'); -} + if (count($formErrors) > 0) unsetPostRequestParameter('ok'); +} // END - if -if ((isFormSent()) && (count($FORM_ERRORS) == 0)) { +if ((isFormSent()) && (count($formErrors) == 0)) { // Generate message array $messageArray = array( 'failed' => '{--SPONSOR_REGISTRATION_FAILED--}', @@ -259,7 +259,7 @@ ORDER BY } // END - foreach // Check for invalid entries - if (count($FORM_ERRORS) > 0) { + if (count($formErrors) > 0) { // Some found... :-( foreach (array('company','position','tax_ident','surname','family','street_nr1','street_nr2','country','zip','city','phone','fax','cell','email','url') as $entry) { $content[$entry] = secureString(postRequestParameter($entry)); @@ -282,10 +282,10 @@ ORDER BY $OUT = ''; // Errors found? - if (count($FORM_ERRORS) > 0) { + if (count($formErrors) > 0) { $OUT = loadTemplate('admin_settings_saved', true, '{--SPONSOR_REGISTER_SOMETHING_MISSING--}'); $OUT .= '
    '; - foreach ($FORM_ERRORS as $error) { + foreach ($formErrors as $error) { $OUT .= '
  1. ' . $error . '
  2. '; } // END - foreach @@ -293,7 +293,15 @@ ORDER BY } // END - if $content['form_errors'] = $OUT; - $content['refid'] = bigintval(postRequestParameter('refid')); + + // @TODO Maybe a default referal id? + $content['refid'] = 0; + + // Is the referal id valid? + if ((isPostRequestParameterSet('refid')) && (isValidUserId(postRequestParameter('refid')))) { + // Transfer referal id + $content['refid'] = bigintval(postRequestParameter('refid')); + } // END - if } // END - if // Display registration form diff --git a/inc/modules/sponsor.php b/inc/modules/sponsor.php index 6473576247..9a84af61a5 100644 --- a/inc/modules/sponsor.php +++ b/inc/modules/sponsor.php @@ -46,7 +46,7 @@ if (!defined('__SECURITY')) { // No sponsor! addFatalMessage(__FILE__, __LINE__, '{--SPONSOR_ONLY_AREA_ENTERED--}'); return; -} elseif (!isWhatSet()) { +} elseif ((!isWhatSet()) || (getWhat() == '')) { // Empty what value detected! setWhat('welcome'); } diff --git a/inc/modules/sponsor/.php b/inc/modules/sponsor/.php index e1beb6300a..85198439ae 100644 --- a/inc/modules/sponsor/.php +++ b/inc/modules/sponsor/.php @@ -48,8 +48,8 @@ if (!defined('__SECURITY')) { return; } -// Put all HTML code into $OUT! -// E.g.: $OUT = loadTemplate('sponsor_template', true); +// Put all HTML code into $GLOBALS['sponsor_output']! +// E.g.: $GLOBALS['sponsor_output'] = loadTemplate('sponsor_template', true); // [EOF] ?> diff --git a/inc/modules/sponsor/account.php b/inc/modules/sponsor/account.php index e76cdacf09..76889dc415 100644 --- a/inc/modules/sponsor/account.php +++ b/inc/modules/sponsor/account.php @@ -51,7 +51,7 @@ if (!defined('__SECURITY')) { // Data for the formular $result = SQL_QUERY_ESC("SELECT - `company`, `position`, `tax_ident`, + `id`, `company`, `position`, `tax_ident`, `gender`, `surname`, `family`, `street_nr1`, `street_nr2`, `zip`, `city`, `country`, `phone`, `fax`, `cell`, `email`, `url`, `status`, `receive_warnings` @@ -120,10 +120,10 @@ if (SQL_NUMROWS($result) == 1) { if (!empty($message)) { // Output message - $OUT = loadTemplate('admin_settings_saved', true, $message); + $GLOBALS['sponsor_output'] = loadTemplate('admin_settings_saved', true, $message); } else { // No message generated - $OUT = loadTemplate('admin_settings_saved', true, '{--SPONSOR_NO_MESSAGE_GENERATED--}'); + $GLOBALS['sponsor_output'] = loadTemplate('admin_settings_saved', true, '{--SPONSOR_NO_MESSAGE_GENERATED--}'); } } else { // Init gender @@ -135,16 +135,16 @@ if (SQL_NUMROWS($result) == 1) { $content['gender_' . strtolower($content['gender'])] = ' selected="selected"'; // Output formular - $OUT = loadTemplate('sponsor_account_form', true, $content); + $GLOBALS['sponsor_output'] = loadTemplate('sponsor_account_form', true, $content); } } else { // Locked or so? $STATUS = sponsorTranslateUserStatus($content['status']); - $OUT = loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_ACCOUNT_FAILED', $STATUS)); + $GLOBALS['sponsor_output'] = loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_ACCOUNT_FAILED', $STATUS)); } } else { // Sponsor account not found! - $OUT = loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_ACCOUNT_404', getSession('sponsor_id'))); + $GLOBALS['sponsor_output'] = loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_ACCOUNT_404', getSession('sponsor_id'))); } // Free memory diff --git a/inc/modules/sponsor/settings.php b/inc/modules/sponsor/settings.php index 76f73ac9f6..636697afcf 100644 --- a/inc/modules/sponsor/settings.php +++ b/inc/modules/sponsor/settings.php @@ -101,10 +101,10 @@ if (SQL_NUMROWS($result) == 1) { if (!empty($message)) { // Output message - $OUT = loadTemplate('admin_settings_saved', true, $message); + $GLOBALS['sponsor_output'] = loadTemplate('admin_settings_saved', true, $message); } else { // No message generated - $OUT = loadTemplate('admin_settings_saved', true, '{--SPONSOR_NO_MESSAGE_GENERATED--}'); + $GLOBALS['sponsor_output'] = loadTemplate('admin_settings_saved', true, '{--SPONSOR_NO_MESSAGE_GENERATED--}'); } } else { // Make yes/no selection @@ -113,16 +113,16 @@ if (SQL_NUMROWS($result) == 1) { $content['receive_warnings_' . strtolower($content['receive_warnings'])] = ' checked="checked"'; // Output formular - $OUT = loadTemplate('sponsor_settings_form', true, $content); + $GLOBALS['sponsor_output'] = loadTemplate('sponsor_settings_form', true, $content); } } else { // Locked or so? $STATUS = sponsorTranslateUserStatus($content['status']); - $OUT = loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_ACCOUNT_FAILED', $STATUS)); + $GLOBALS['sponsor_output'] = loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_ACCOUNT_FAILED', $STATUS)); } } else { // Sponsor account not found! - $OUT = loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_ACCOUNT_404', getSession('sponsor_id'))); + $GLOBALS['sponsor_output'] = loadTemplate('admin_settings_saved', true, getMaskedMessage('SPONSOR_ACCOUNT_404', getSession('sponsor_id'))); } // Free memory diff --git a/inc/modules/sponsor/welcome.php b/inc/modules/sponsor/welcome.php index 7aac1a7a27..88ec34677a 100644 --- a/inc/modules/sponsor/welcome.php +++ b/inc/modules/sponsor/welcome.php @@ -51,7 +51,7 @@ if (!defined('__SECURITY')) { // Load some data $result = SQL_QUERY_ESC("SELECT - `gender`, `surname`, `family`, (`points_amount` - `points_used`) AS points + `id`, `gender`, `surname`, `family`, (`points_amount` - `points_used`) AS points FROM `{?_MYSQL_PREFIX?}_sponsor_data` WHERE @@ -70,7 +70,7 @@ $content = SQL_FETCHARRAY($result); SQL_FREERESULT($result); // Load main template -$OUT = loadTemplate('sponsor_welcome', true, $content); +$GLOBALS['sponsor_output'] = loadTemplate('sponsor_welcome', true, $content); // [EOF] ?> diff --git a/templates/de/emails/admin/admin_sponsor_change_data.tpl b/templates/de/emails/admin/admin_sponsor_change_data.tpl index e4cdbbaafe..f3749b377f 100644 --- a/templates/de/emails/admin/admin_sponsor_change_data.tpl +++ b/templates/de/emails/admin/admin_sponsor_change_data.tpl @@ -9,7 +9,7 @@ Hier sind alle neuen (und in Klammern alten) Daten: {--SPONSOR_ENTER_TAX_IDENT--}: $content[new_data][tax_ident] ($content[tax_ident]) ------------------------------ {--GUEST_GENDER--}: {%pipe,translateGender=$content[new_data][gender]%} ({%pipe,translateGender=$content[gender]%}) -{--SURNAME_FAMILY--}: $content[new_data][surname] $content[new_data][family] ({%sponsor,surname=$userid%} {%sponsor,family=$userid%}) +{--SURNAME_FAMILY--}: $content[new_data][surname] $content[new_data][family] ({%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}) {--SPONSOR_EMAIL_STREET_NR1--}: $content[new_data][street_nr1] ($content[street_nr1]) {--SPONSOR_EMAIL_STREET_NR2--}: $content[new_data][street_nr2] ($content[street_nr2]) {--SPONSOR_EMAIL_CNTRY_ZIP_CITY--}: $content[new_data][country]-$content[new_data][zip] $content[new_data][city] ($content[country]-$content[zip] $content[city]) diff --git a/templates/de/emails/admin/admin_sponsor_change_email.tpl b/templates/de/emails/admin/admin_sponsor_change_email.tpl index 351b955802..30b7b835e7 100644 --- a/templates/de/emails/admin/admin_sponsor_change_email.tpl +++ b/templates/de/emails/admin/admin_sponsor_change_email.tpl @@ -9,7 +9,7 @@ Hier sind alle neuen (und in Klammern alten) Daten: {--SPONSOR_ENTER_TAX_IDENT--}: $content[new_data][tax_ident] ($content[tax_ident]) ------------------------------ {--GUEST_GENDER--}: {%pipe,translateGender=$content[new_data][gender]%} ({%pipe,translateGender=$content[gender]%}) -{--SURNAME_FAMILY--}: $content[new_data][surname] $content[new_data][family] ({%sponsor,surname=$userid%} {%sponsor,family=$userid%}) +{--SURNAME_FAMILY--}: $content[new_data][surname] $content[new_data][family] ({%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}) {--SPONSOR_EMAIL_STREET_NR1--}: $content[new_data][street_nr1] ($content[street_nr1]) {--SPONSOR_EMAIL_STREET_NR2--}: $content[new_data][street_nr2] ($content[street_nr2]) {--SPONSOR_EMAIL_CNTRY_ZIP_CITY--}: $content[new_data][country]-$content[new_data][zip] $content[new_data][city] ($content[country]-$content[zip] $content[city]) diff --git a/templates/de/emails/admin/admin_sponsor_edit.tpl b/templates/de/emails/admin/admin_sponsor_edit.tpl index eefa78d06f..90871c2ea3 100644 --- a/templates/de/emails/admin/admin_sponsor_edit.tpl +++ b/templates/de/emails/admin/admin_sponsor_edit.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, ------------------------------ Ihre Sponsor-Id lautet: $content[id] @@ -12,8 +12,8 @@ Es sind nun folgende Daten gesetzt: {--SPONSOR_ENTER_COMPANY_POSITION--}: $content[position] {--SPONSOR_ENTER_TAX_IDENT--}: $content[tax_ident] ------------------------------ -{--GUEST_GENDER--}: {%sponsor,gender,translateGender=$userid%} -{--SURNAME_FAMILY--}: {%sponsor,surname=$userid%} {%sponsor,family=$userid%} +{--GUEST_GENDER--}: {%sponsor,gender,translateGender=$content[id]%} +{--SURNAME_FAMILY--}: {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%} {--SPONSOR_EMAIL_STREET_NR1--}: $content[street_nr1] {--SPONSOR_EMAIL_STREET_NR2--}: $content[street_nr2] {--SPONSOR_EMAIL_CNTRY_ZIP_CITY--}: $content[country]-$content[zip] $content[city] diff --git a/templates/de/emails/admin/admin_sponsor_pending.tpl b/templates/de/emails/admin/admin_sponsor_pending.tpl index cc5a08e37d..b7086cc993 100644 --- a/templates/de/emails/admin/admin_sponsor_pending.tpl +++ b/templates/de/emails/admin/admin_sponsor_pending.tpl @@ -18,9 +18,9 @@ Ihre Sponsor-Id lautet: $content[id] ------------------------------ Anrede: {%pipe,translateGender=$content[gender]%} ------------------------------ -Vorname: {%sponsor,surname=$userid%} +Vorname: {%sponsor,surname=$content[id]%} ------------------------------ -Nachname: {%sponsor,family=$userid%} +Nachname: {%sponsor,family=$content[id]%} ------------------------------ -- Firmendaten: -- ------------------------------ diff --git a/templates/de/emails/del_sponsor.tpl b/templates/de/emails/del_sponsor.tpl index cc4d16e98a..c2e7502b3e 100644 --- a/templates/de/emails/del_sponsor.tpl +++ b/templates/de/emails/del_sponsor.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Einer unserer Administratoren hat soeben Ihren Account gelöscht! @@ -6,7 +6,7 @@ Grund der Loeschung war folgender: ------------------------------------ $content[reason] ------------------------------------ -Ihre Sponsor-Id war: $userid +Ihre Sponsor-Id war: $content[id] ------------------------------------ Wir wünschen Ihnen weiterhin noch alles Gute und können Sie vielleicht irgentwann einmal wieder als Sponsor begruessen. diff --git a/templates/de/emails/lock_sponsor.tpl b/templates/de/emails/lock_sponsor.tpl index 40c9a3ff58..366b019a37 100644 --- a/templates/de/emails/lock_sponsor.tpl +++ b/templates/de/emails/lock_sponsor.tpl @@ -1,7 +1,7 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, -------------------------- -Ihre Sponsor-Id bei uns: $userid +Ihre Sponsor-Id bei uns: $content[id] -------------------------- $content[message] diff --git a/templates/de/emails/sponsor/sponsor_activate.tpl b/templates/de/emails/sponsor/sponsor_activate.tpl index 12226be3eb..1255ee69f5 100644 --- a/templates/de/emails/sponsor/sponsor_activate.tpl +++ b/templates/de/emails/sponsor/sponsor_activate.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Sie (oder ein anderer mit der IP-Nummer {%server,remote_addr%}) haben soeben Ihren Bestätigungslink erneut angefordert. diff --git a/templates/de/emails/sponsor/sponsor_add_points.tpl b/templates/de/emails/sponsor/sponsor_add_points.tpl index 945f2d245f..0151bb5804 100644 --- a/templates/de/emails/sponsor/sponsor_add_points.tpl +++ b/templates/de/emails/sponsor/sponsor_add_points.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Einer unserer Administratoren hat Ihnen soeben {%pipe,translateComma=$content[points]%} {?POINTS?} Ihrem Sponsoren-Account mit der id $content[id] gutgeschrieben! diff --git a/templates/de/emails/sponsor/sponsor_change_data.tpl b/templates/de/emails/sponsor/sponsor_change_data.tpl index 9442472c1d..1ab83fbe03 100644 --- a/templates/de/emails/sponsor/sponsor_change_data.tpl +++ b/templates/de/emails/sponsor/sponsor_change_data.tpl @@ -4,15 +4,15 @@ Sie haben heute Ihre Daten geaendert. Hier sind alle neuen (und in Klammern alten) Daten: ------------------------------ -{--SPONSOR_ENTER_COMPANY_TITLE--}: $content[company] ({%sponsor,company=$userid%}) -{--SPONSOR_ENTER_COMPANY_POSITION--}: $content[position] ({%sponsor,position=$userid%}) -{--SPONSOR_ENTER_TAX_IDENT--}: $content[tax_ident] ({%sponsor,tax_ident=$userid%}) ------------------------------- -{--GUEST_GENDER--}: $content[gender] ({%sponsor,gender,translateGender=$userid%}) -{--SURNAME_FAMILY--}: $content[surname] $content[family] ({%sponsor,surname=$userid%} {%sponsor,family=$userid%}) -{--SPONSOR_EMAIL_STREET_NR1--}: $content[street_nr1] ({%sponsor,street_nr1=$userid%}) -{--SPONSOR_EMAIL_STREET_NR2--}: $content[street_nr2] ({%sponsor,street_nr2=$userid%}) -{--SPONSOR_EMAIL_CNTRY_ZIP_CITY--}: $content[country]-$content[zip] $content[city] ({%sponsor,country,determineCountry=$userid%}-{%sponsor,zip,bigintval=$userid%} {%sponsor,city=$userid%}) +{--SPONSOR_ENTER_COMPANY_TITLE--}: $content[company] ({%sponsor,company=$content[id]%}) +{--SPONSOR_ENTER_COMPANY_POSITION--}: $content[position] ({%sponsor,position=$content[id]%}) +{--SPONSOR_ENTER_TAX_IDENT--}: $content[tax_ident] ({%sponsor,tax_ident=$content[id]%}) +------------------------------ +{--GUEST_GENDER--}: $content[gender] ({%sponsor,gender,translateGender=$content[id]%}) +{--SURNAME_FAMILY--}: $content[surname] $content[family] ({%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}) +{--SPONSOR_EMAIL_STREET_NR1--}: $content[street_nr1] ({%sponsor,street_nr1=$content[id]%}) +{--SPONSOR_EMAIL_STREET_NR2--}: $content[street_nr2] ({%sponsor,street_nr2=$content[id]%}) +{--SPONSOR_EMAIL_CNTRY_ZIP_CITY--}: $content[country]-$content[zip] $content[city] ({%sponsor,country,determineSponsorCountry=$content[id]%}-{%sponsor,zip,bigintval=$content[id]%} {%sponsor,city=$content[id]%}) ------------------------------ {--SPONSOR_ENTER_PHONE--}: $content[phone] ($content[phone]) {--SPONSOR_ENTER_FAX--}: $content[fax] ($content[fax]) diff --git a/templates/de/emails/sponsor/sponsor_confirm.tpl b/templates/de/emails/sponsor/sponsor_confirm.tpl index 112316a999..6023a4c90a 100644 --- a/templates/de/emails/sponsor/sponsor_confirm.tpl +++ b/templates/de/emails/sponsor/sponsor_confirm.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Sie (oder ein anderer mit der IP-Nummer {%server,remote_addr%}) haben sich soeben als Sponsor zu unserem {?mt_word?} angemeldet. Sie haben somit den ersten Schritt zu uns getan wofür wir uns sehr bedanken. diff --git a/templates/de/emails/sponsor/sponsor_email.tpl b/templates/de/emails/sponsor/sponsor_email.tpl index 0535d99cb3..90b15d069b 100644 --- a/templates/de/emails/sponsor/sponsor_email.tpl +++ b/templates/de/emails/sponsor/sponsor_email.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Sie hatten bei uns Ihre EMail-Adresse geändert und den Bestätigungslink erneut angefordert. Hier sind nun alle nötigen Daten dazu. diff --git a/templates/de/emails/sponsor/sponsor_lost.tpl b/templates/de/emails/sponsor/sponsor_lost.tpl index d3e246943a..84700abcad 100644 --- a/templates/de/emails/sponsor/sponsor_lost.tpl +++ b/templates/de/emails/sponsor/sponsor_lost.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Sie (oder ein anderer mit der IP-Nummer {%server,remote_addr%}) haben soeben ein neues Passwort angefordert. diff --git a/templates/de/emails/sponsor/sponsor_pending.tpl b/templates/de/emails/sponsor/sponsor_pending.tpl index fd034d774e..dad61edde5 100644 --- a/templates/de/emails/sponsor/sponsor_pending.tpl +++ b/templates/de/emails/sponsor/sponsor_pending.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Sie haben soeben Ihre EMail-Adresse bestätigt. Dies wurde von der IP-Nummer {%server,remote_addr%} aus durchgefuehrt. @@ -17,31 +17,31 @@ Ihre Sponsor-Id lautet: $content[id] ------------------------------ -- Persoenliche Daten: -- ------------------------------ -Anrede: {%sponsor,gender,translateGender=$userid%} +Anrede: {%sponsor,gender,translateGender=$content[id]%} ------------------------------ -Vorname: {%sponsor,surname=$userid%} +Vorname: {%sponsor,surname=$content[id]%} ------------------------------ -Nachname: {%sponsor,family=$userid%} +Nachname: {%sponsor,family=$content[id]%} ------------------------------ -- Firmendaten: -- ------------------------------ -Firmenname: {%sponsor,company=$userid%} +Firmenname: {%sponsor,company=$content[id]%} ------------------------------ -Position: {%sponsor,position=$userid%} +Position: {%sponsor,position=$content[id]%} ------------------------------ -Ust-Ident-Nr.: {%sponsor,tax_ident=$userid%} +Ust-Ident-Nr.: {%sponsor,tax_ident=$content[id]%} ------------------------------ -- Kontaktdaten: -- ------------------------------ -Strasse, Zeile 1: {%sponsor,street_nr1=$userid%} +Strasse, Zeile 1: {%sponsor,street_nr1=$content[id]%} ------------------------------ -Strasse, Zeile 2: {%sponsor,street_nr2=$userid%} +Strasse, Zeile 2: {%sponsor,street_nr2=$content[id]%} ------------------------------ -Ländercode: {%sponsor,country,determineCountry=$userid%} +Ländercode: {%sponsor,country,determineSponsorCountry=$content[id]%} ------------------------------ -Postleitzahl: {%sponsor,zip,bigintval=$userid%} +Postleitzahl: {%sponsor,zip,bigintval=$content[id]%} ------------------------------ -Wohnort: {%sponsor,city=$userid%} +Wohnort: {%sponsor,city=$content[id]%} ------------------------------ Telefonnummer: $content[phone] ------------------------------ diff --git a/templates/de/emails/sponsor/sponsor_ref_notify.tpl b/templates/de/emails/sponsor/sponsor_ref_notify.tpl index f6048435a7..bedb5dfd72 100644 --- a/templates/de/emails/sponsor/sponsor_ref_notify.tpl +++ b/templates/de/emails/sponsor/sponsor_ref_notify.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, ------------------------------ Ihre Sponsor-Id lautet: $content[id] diff --git a/templates/de/emails/sponsor/sponsor_settings.tpl b/templates/de/emails/sponsor/sponsor_settings.tpl index a0ec011bd7..103f348c8e 100644 --- a/templates/de/emails/sponsor/sponsor_settings.tpl +++ b/templates/de/emails/sponsor/sponsor_settings.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Sie haben heute Ihre Einstellungen geaendert. diff --git a/templates/de/emails/sponsor/sponsor_sub_points.tpl b/templates/de/emails/sponsor/sponsor_sub_points.tpl index 28f1e6e5f5..55f0e08ce9 100644 --- a/templates/de/emails/sponsor/sponsor_sub_points.tpl +++ b/templates/de/emails/sponsor/sponsor_sub_points.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Einer unserer Administratoren hat Ihnen soeben {%pipe,translateComma=$content[points]%} {?POINTS?} von Ihrem Sponsoren-Account mit der id $content[id] abgezogen! diff --git a/templates/de/emails/sponsor/sponsor_unlock.tpl b/templates/de/emails/sponsor/sponsor_unlock.tpl index 12226be3eb..1255ee69f5 100644 --- a/templates/de/emails/sponsor/sponsor_unlock.tpl +++ b/templates/de/emails/sponsor/sponsor_unlock.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, Sie (oder ein anderer mit der IP-Nummer {%server,remote_addr%}) haben soeben Ihren Bestätigungslink erneut angefordert. diff --git a/templates/de/emails/sponsor/sponsor_unlocked.tpl b/templates/de/emails/sponsor/sponsor_unlocked.tpl index 473b404b97..077bf49875 100644 --- a/templates/de/emails/sponsor/sponsor_unlocked.tpl +++ b/templates/de/emails/sponsor/sponsor_unlocked.tpl @@ -1,4 +1,4 @@ -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}, +Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}, ------------------------------ Ihre Sponsor-Id lautet: $content[id] diff --git a/templates/de/html/guest/guest_menu_whats.tpl b/templates/de/html/guest/guest_menu_whats.tpl index 9bf5b19391..11f5d85d80 100644 --- a/templates/de/html/guest/guest_menu_whats.tpl +++ b/templates/de/html/guest/guest_menu_whats.tpl @@ -1,8 +1 @@ - - -
    - · - $content -
    - - + diff --git a/templates/de/html/member/member_menu_whats.tpl b/templates/de/html/member/member_menu_whats.tpl index 68b8776a7a..11f5d85d80 100644 --- a/templates/de/html/member/member_menu_whats.tpl +++ b/templates/de/html/member/member_menu_whats.tpl @@ -1,8 +1 @@ - - -
    - · - $content -
    - - + diff --git a/templates/de/html/sponsor/sponsor_account_form.tpl b/templates/de/html/sponsor/sponsor_account_form.tpl index e266275811..c104ff0e9b 100644 --- a/templates/de/html/sponsor/sponsor_account_form.tpl +++ b/templates/de/html/sponsor/sponsor_account_form.tpl @@ -11,7 +11,7 @@ {--SPONSOR_ENTER_COMPANY_TITLE--}: - + @@ -19,7 +19,7 @@ {--SPONSOR_ENTER_COMPANY_POSITION--}: - + @@ -27,7 +27,7 @@ {--SPONSOR_ENTER_TAX_IDENT--}: - + @@ -52,7 +52,7 @@ {--GUEST_SURNAME--}: - + @@ -60,7 +60,7 @@ {--GUEST_FAMILY--}: - + @@ -73,7 +73,7 @@ {--SPONSOR_ENTER_STREET_NR1--}: - + @@ -81,7 +81,7 @@ {--SPONSOR_ENTER_STREET_NR2--}: - + @@ -89,8 +89,8 @@ {--SPONSOR_ENTER_CNTRY_ZIP_CITY--}: - - - + - + diff --git a/templates/de/html/sponsor/sponsor_action.tpl b/templates/de/html/sponsor/sponsor_action.tpl index 70275b57a2..81feff4569 100644 --- a/templates/de/html/sponsor/sponsor_action.tpl +++ b/templates/de/html/sponsor/sponsor_action.tpl @@ -1,4 +1,5 @@ - +
    +
    $content[menu] + diff --git a/templates/de/html/sponsor/sponsor_header.tpl b/templates/de/html/sponsor/sponsor_header.tpl index d47a0c0073..5b2c21c549 100644 --- a/templates/de/html/sponsor/sponsor_header.tpl +++ b/templates/de/html/sponsor/sponsor_header.tpl @@ -1,3 +1,3 @@ -
    +
    Willkommen zum Sponsorenbereich von {?MAIN_TITLE?}
    diff --git a/templates/de/html/sponsor/sponsor_welcome.tpl b/templates/de/html/sponsor/sponsor_welcome.tpl index 90cdd38a8e..dc214fed8f 100644 --- a/templates/de/html/sponsor/sponsor_welcome.tpl +++ b/templates/de/html/sponsor/sponsor_welcome.tpl @@ -1,11 +1,11 @@
    -Hallo {%sponsor,gender,translateGender=$userid%} {%sponsor,surname=$userid%} {%sponsor,family=$userid%}! + Hallo {%sponsor,gender,translateGender=$content[id]%} {%sponsor,surname=$content[id]%} {%sponsor,family=$content[id]%}!
    -Schön, dass wir Sie wieder in unserem Sponsorenbereich begrüssen dürfen! + Schön, dass wir Sie wieder in unserem Sponsorenbereich begrüssen dürfen!
    -Sie haben noch {%pipe,translateComma=$content[points]%} {?POINTS?} für weitere Sponsorenaktionen übrig. + Sie haben noch {%pipe,translateComma=$content[points]%} {?POINTS?} für weitere Sponsorenaktionen übrig.
    diff --git a/templates/de/html/sponsor/sponsor_what.tpl b/templates/de/html/sponsor/sponsor_what.tpl index d493cc88bf..4dceaefee7 100644 --- a/templates/de/html/sponsor/sponsor_what.tpl +++ b/templates/de/html/sponsor/sponsor_what.tpl @@ -1,6 +1,8 @@ - · - $content[title] + + · + $content[title] + diff --git a/theme/business/css/general.css b/theme/business/css/general.css index e7cd475405..fd405cb6c3 100644 --- a/theme/business/css/general.css +++ b/theme/business/css/general.css @@ -292,8 +292,7 @@ a.admin_logout { border: 1px solid #000000; } -.guest_menu_row, .guest_menu_bottom, .member_menu_row, .member_menu_bottom - { +.guest_menu_row, .guest_menu_bottom, .member_menu_row, .member_menu_bottom { border: 1px solid #000000; border-top: 0px; background-color: #ffffff; diff --git a/theme/business/css/sponsor.css b/theme/business/css/sponsor.css index 5e51c8bd5a..4b609d83b9 100644 --- a/theme/business/css/sponsor.css +++ b/theme/business/css/sponsor.css @@ -3,7 +3,7 @@ } .sponsor_what { - height: 24px; + height: 22px; } .sponsor_header, .sponsor_footer { @@ -12,5 +12,11 @@ .sponsor_action { background-color: #EEEEFF; - height: 25px; + height: 22px; +} + +.sponsor_menu { + margin: 0px; + padding: 0px; + width: 200px; } diff --git a/theme/default/css/general.css b/theme/default/css/general.css index 3292bbcf39..ec294ad598 100644 --- a/theme/default/css/general.css +++ b/theme/default/css/general.css @@ -324,8 +324,7 @@ a.admin_logout { border: 1px solid #00aa44; } -.guest_menu_row, .guest_menu_bottom, .member_menu_row, .member_menu_bottom - { +.guest_menu_row, .guest_menu_bottom, .member_menu_row, .member_menu_bottom { border: 1px solid #00aa44; border-top: 0px; background-color: #eeffbc; diff --git a/theme/default/css/sponsor.css b/theme/default/css/sponsor.css index 924d6d0fec..3e2ad862f0 100644 --- a/theme/default/css/sponsor.css +++ b/theme/default/css/sponsor.css @@ -8,9 +8,15 @@ .sponsor_action { background-color: #CCDDCC; - height: 25px; + height: 22px; } .sponsor_what { - height: 24px; + height: 22px; +} + +.sponsor_menu { + margin: 0px; + padding: 0px; + width: 200px; } diff --git a/theme/desert/css/sponsor.css b/theme/desert/css/sponsor.css index 4ae7594bff..5cd65ae4e1 100644 --- a/theme/desert/css/sponsor.css +++ b/theme/desert/css/sponsor.css @@ -4,7 +4,7 @@ .sponsor_action { background-color: #DDDDAA; - height: 25px; + height: 22px; } .sponsor_header, .sponsor_footer { @@ -13,16 +13,11 @@ .sponsor_what { background-color: #FFFFCC; - height: 24px; + height: 22px; } -TR.sponsor_row_blur:hover { - background-color: #DDDDAA; +.sponsor_menu { + margin: 0px; + padding: 0px; + width: 200px; } - -A.sponsor_blur { - display: block; - height: 33px; - padding-top: 9px; - padding-left: 7px; -} \ No newline at end of file diff --git a/theme/org/css/sponsor.css b/theme/org/css/sponsor.css index d703841371..3e2ad862f0 100644 --- a/theme/org/css/sponsor.css +++ b/theme/org/css/sponsor.css @@ -1,25 +1,22 @@ .sponsor_table { - background-color : #DDEEDD; + background-color: #DDEEDD; } .sponsor_header, .sponsor_footer { - background-color : #CCDDCC; + background-color: #CCDDCC; } .sponsor_action { - background-color : #CCDDCC; - height : 27px; + background-color: #CCDDCC; + height: 22px; } .sponsor_what { - height : 24px; + height: 22px; } -.sponsor_menu_blur { - display : block; - height : 24px; -} - -.sponsor_menu_blur:hover { - background-color : #CCDDCC; +.sponsor_menu { + margin: 0px; + padding: 0px; + width: 200px; } -- 2.39.5