fooRequestElementBar() functions renamed, adding of request parameters added:
[mailer.git] / inc / modules / admin / what-edit_user.php
index fa9f1b17004809b2a1ae37789ea64fadf9b8651e..6922dbedb93b0ab40773e97c5b2c79d110030faf 100644 (file)
@@ -48,7 +48,7 @@ addMenuDescription('admin', __FILE__);
 
 // Fix a notice
 $result_main = false;
-if (isGetRequestElementSet('userid')) {
+if (isGetRequestParameterSet('userid')) {
        // Load user entry
        $result_main = SQL_QUERY_ESC("SELECT
        `userid`, `gender`, `surname`, `family`, `street_nr`, `zip`, `city`, `country`,
@@ -61,25 +61,25 @@ WHERE
        `userid`=%s
 LIMIT 1",
                array(
-                       bigintval(getRequestElement('userid'))
+                       bigintval(getRequestParameter('userid'))
                ), __FILE__, __LINE__);
 } // END - if
 
-if ((SQL_NUMROWS($result_main) == 1) || (!isGetRequestElementSet('userid'))) {
+if ((SQL_NUMROWS($result_main) == 1) || (!isGetRequestParameterSet('userid'))) {
        // User found
-       if (!isGetRequestElementSet('userid')) {
+       if (!isGetRequestParameterSet('userid')) {
                // Output selection form with all confirmed user accounts listed
                addMemberSelectionBox();
-       } elseif (isPostRequestElementSet('edit')) {
+       } elseif (isPostRequestParameterSet('edit')) {
                // Ok, change the account...
                $updateUser = false; $add = '';
-               if ((!isPostRequestElementSet('pass1')) && (!isPostRequestElementSet('pass2'))) {
+               if ((!isPostRequestParameterSet('pass1')) && (!isPostRequestParameterSet('pass2'))) {
                        // Don't change the password
                        $updateUser = true;
-               } elseif ((postRequestElement('pass1') == postRequestElement('pass2'))) {
+               } elseif ((postRequestParameter('pass1') == postRequestParameter('pass2'))) {
                        // Change the password
                        $updateUser = true;
-                       $add = ", `password`='" . generateHash(postRequestElement('pass1')) . "'";
+                       $add = ", `password`='" . generateHash(postRequestParameter('pass1')) . "'";
                }
 
                if ($updateUser === true) {
@@ -100,15 +100,15 @@ WHERE
        `userid`=%s
 LIMIT 1",
                        array(
-                               substr(postRequestElement('gender'), 0, 1),
-                               postRequestElement('surname'),
-                               postRequestElement('family'),
-                               postRequestElement('street_nr'),
-                               postRequestElement('country'),
-                               bigintval(postRequestElement('zip')),
-                               postRequestElement('city'),
-                               postRequestElement('email'),
-                               bigintval(getRequestElement('userid')),
+                               substr(postRequestParameter('gender'), 0, 1),
+                               postRequestParameter('surname'),
+                               postRequestParameter('family'),
+                               postRequestParameter('street_nr'),
+                               postRequestParameter('country'),
+                               bigintval(postRequestParameter('zip')),
+                               postRequestParameter('city'),
+                               postRequestParameter('email'),
+                               bigintval(getRequestParameter('userid')),
                        ), __FILE__, __LINE__);
                        $content = getMessage('USER_ACCOUNT_SAVED');
                } else {
@@ -135,7 +135,7 @@ LIMIT 1",
        }
 } else {
        // Account does not exists!
-       loadTemplate('admin_settings_saved', false, '<div class="admin_failed">' . getMaskedMessage('ADMIN_MEMBER_404', getRequestElement('userid')) . '</div>');
+       loadTemplate('admin_settings_saved', false, '<div class="admin_failed">' . getMaskedMessage('ADMIN_MEMBER_404', getRequestParameter('userid')) . '</div>');
 }
 
 // Free the result