Rewrite to display correct message
authorRoland Häder <roland@mxchange.org>
Tue, 3 Nov 2009 22:55:45 +0000 (22:55 +0000)
committerRoland Häder <roland@mxchange.org>
Tue, 3 Nov 2009 22:55:45 +0000 (22:55 +0000)
inc/modules/member/what-mydata.php
templates/de/html/member/member_mydata_locked.tpl

index adbd169..79a408a 100644 (file)
@@ -144,7 +144,8 @@ 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);
+                       $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);
                } else {
@@ -211,13 +212,13 @@ LIMIT 1",
                // Free result
                SQL_FREERESULT($result);
 
-               $content['last_change'] = $content['last_update'] + getConfig('profile_lock');
+               $content['update_check'] = $content['last_update'] + getConfig('profile_lock');
 
                // How far is last change on his profile away from now?
-               if (($content['last_change'] > time()) && (!isAdmin()) && (getConfig('profile_lock') > 0)) {
-                       $content['last_change'] = generateDateTime($content['last_change'] + getConfig('profile_lock'), 0);
+               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');
+                       loadTemplate('member_mydata_locked', false, $content);
                } elseif ((!isEmailValid(postRequestElement('email'))) && (!isAdmin())) {
                        // Invalid email address!
                        loadTemplate('admin_settings_saved', false, getMessage('INVALID_EMAIL_ADDRESS_ENTERED'));
index 59e5c9d..b42a053 100644 (file)
@@ -3,7 +3,7 @@
                <td height="7" class="seperator">&nbsp;</td>
        </tr>
        <tr>
-               <td align="center">{--MEMBER_PROFILE_LOCKED_1--}$content[update_check]{--MEMBER_PROFILE_LOCKED_2--}</td>
+               <td align="center">$content[update_check]</td>
        </tr>
        <tr>
                <td height="7" class="seperator">&nbsp;</td>