]> git.mxchange.org Git - mailer.git/blobdiff - inc/libs/register_functions.php
A lot calls saved, expression language rewritten:
[mailer.git] / inc / libs / register_functions.php
index 4da3b6027045d2d148f2708923aaa9bd99600fab..e34ccd2b503ccd57c68a7184df3e46d6c15e1021 100644 (file)
@@ -89,12 +89,10 @@ function registerGenerateCategoryTable ($mode, $return=false) {
 
        if (SQL_NUMROWS($result) > 0) {
                // List alle visible modules (or all to the admin)
-               $SW = 2;
                $OUT .= '<table border="0" cellspacing="0" cellpadding="0" width="100%">';
                while ($content = SQL_FETCHARRAY($result)) {
                        // Prepare array for the template
                        $content = array(
-                               'sw'    => $SW,
                                'cat'   => $content['cat'],
                                'def_y' => '',
                                'def_n' => '',
@@ -110,8 +108,7 @@ function registerGenerateCategoryTable ($mode, $return=false) {
 
                        // Load template and switch color
                        $OUT .= loadTemplate('guest_cat_row', true, $content);
-                       $SW = 3 - $SW;
-               }
+               } // END - while
                $OUT .= '</table>';
 
                // Free memory
@@ -277,14 +274,14 @@ function doRegistration () {
 
        // Generate hash which will be inserted into confirmation mail
        $hash = generateHash(sha1(
-               $confirmedUsers . getConfig('ENCRYPT_SEPERATOR') .
-               $unconfirmedUsers . getConfig('ENCRYPT_SEPERATOR') .
-               $lockedUsers . getConfig('ENCRYPT_SEPERATOR') .
+               $confirmedUsers . getEncryptSeperator() .
+               $unconfirmedUsers . getEncryptSeperator() .
+               $lockedUsers . getEncryptSeperator() .
                postRequestParameter('month') . '-' .
                postRequestParameter('day') . '-' .
-               postRequestParameter('year') . getConfig('ENCRYPT_SEPERATOR') .
-               detectServerName() . getConfig('ENCRYPT_SEPERATOR') .
-               detectRemoteAddr() . getConfig('ENCRYPT_SEPERATOR') .
+               postRequestParameter('year') . getEncryptSeperator() .
+               detectServerName() . getEncryptSeperator() .
+               detectRemoteAddr() . getEncryptSeperator() .
                detectUserAgent() . '/' .
                getConfig('SITE_KEY') . '/' .
                getConfig('DATE_KEY') . '/' .
@@ -412,7 +409,7 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
        } // END - if
 
        // ... rewrite a zero referal id to the main title
-       if (postRequestParameter('refid') == '0') setPostRequestParameter('refid', getConfig('MAIN_TITLE'));
+       if (postRequestParameter('refid') == '0') setPostRequestParameter('refid', getMainTitle());
 
        // Is ZIP code set?
        if (isPostRequestParameterSet('zip')) {
@@ -421,7 +418,7 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
                $content = array(
                        'hash'    => $hash,
                        'userid'  => $userid,
-                       'gender'  => translateGender(postRequestParameter('gender')),
+                       'gender'  => SQL_ESCAPE(postRequestParameter('gender')),
                        'surname' => SQL_ESCAPE(postRequestParameter('surname')),
                        'family'  => SQL_ESCAPE(postRequestParameter('family')),
                        'email'   => SQL_ESCAPE(postRequestParameter('email')),
@@ -437,7 +434,7 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
                $content = array(
                        'hash'    => $hash,
                        'userid'  => $userid,
-                       'gender'  => translateGender(postRequestParameter('gender')),
+                       'gender'  => SQL_ESCAPE(postRequestParameter('gender')),
                        'surname' => SQL_ESCAPE(postRequestParameter('surname')),
                        'family'  => SQL_ESCAPE(postRequestParameter('family')),
                        'email'   => SQL_ESCAPE(postRequestParameter('email')),
@@ -466,11 +463,11 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
 
        // Send mail to user (confirmation link!)
        $email = $content['email'];
-       sendEmail($content['email'], '{--GUEST_SUBJECT_CONFIRM_LINK--}', $messageGuest);
+       sendEmail($content['email'], '{--GUEST_CONFIRM_LINK_SUBJECT--}', $messageGuest);
        $content['email'] = $email;
 
        // Send mail to admin
-       sendAdminNotification(getMessage('ADMIN_SUBJECT_NEW_ACCOUNT'), 'register-admin', $content, $userid);
+       sendAdminNotification('{--ADMIN_NEW_ACCOUNT_SUBJECT--}', 'register-admin', $content, $userid);
 }
 
 // [EOF]