]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/member/what-mydata.php
New functions introduced, several rewrites:
[mailer.git] / inc / modules / member / what-mydata.php
index 799efbc9109816279258892fd5ddea69c8425c9a..e88a8f85532dd0ff6746fe30d7ee0f0b7ed75c06 100644 (file)
@@ -77,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, '<div class="member_failed">' . sprintf(getMessage('MEMBER_PROFILE_LOCKED'), generateDateTime($content['last_update'] + getConfig('profile_lock'), 0)) . '</div>');
+                       $content['change'] = loadTemplate('admin_settings_saved', true, '<div class="member_failed">' . getMaskedMessage('MEMBER_PROFILE_LOCKED', generateDateTime($content['last_update'] + getConfig('profile_lock'), 0)) . '</div>');
                } else {
                        // He is allowed to change his profile
                        $content['change'] = loadTemplate('member_mydata_button', true);
@@ -131,7 +131,7 @@ 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'] = sprintf(getMessage('MEMBER_PROFILE_LOCKED'), generateDateTime($content['update_check'] + getConfig('profile_lock'), 0));
+                       $content['update_check'] = getMaskedMessage('MEMBER_PROFILE_LOCKED', generateDateTime($content['update_check'] + getConfig('profile_lock'), 0));
 
                        // You cannot change your account
                        loadTemplate('admin_settings_saved', false, $content['update_check']);
@@ -180,7 +180,7 @@ LIMIT 1",
                                $content['country'] = $OUT;
                        } else {
                                // Ouput default input box
-                               $content['country'] = "<input type=\"text\" name=\"cntry\" class=\"member_normal\" size=\"2\" maxlength=\"3\" value=\"".$content['country']."\" />";
+                               $content['country'] = '<input type="text" name="cntry" class="member_normal" size="2" maxlength="3" value="' . $content['country'] . '" />';
                        }
 
                        // Load template
@@ -209,10 +209,14 @@ LIMIT 1",
                        $hash = generateHash(postRequestElement('pass1'), substr($content['password'], 0, -40));
                        if ((($hash == $content['password']) || (postRequestElement('pass1') == postRequestElement('pass2'))) && (isPostRequestElementSet('pass1'))) {
                                // Only on simple changes normal mode is active = no email or password changed
-                               $mode = 'normal'; $AND = '';
+                               $mode = 'normal';
+                               $AND = '';
 
                                // Did the user changed the password?
-                               if ($hash != $content['password']) { $AND = ", `password`='".$hash."'"; $mode = 'pass'; }
+                               if ($hash != $content['password']) {
+                                       $AND = ", `password`='" . $hash . "'";
+                                       $mode = 'pass';
+                               } // END - if
 
                                // Or did he changed his password?
                                if (postRequestElement('email') != $content['email']) {