]> git.mxchange.org Git - mailer.git/blobdiff - inc/libs/admins_functions.php
Fixes for refback mail
[mailer.git] / inc / libs / admins_functions.php
index a750428dedf22ae9f5e949c23f90302e4f5a6a75..60a9d02731580fa7ce22c4984e9801c76427e021 100644 (file)
@@ -1,7 +1,7 @@
 <?php
 /************************************************************************
- * MXChange v0.2.1                                    Start: 06/30/2003 *
- * ===============                              Last change: 11/27/2004 *
+ * Mailer v0.2.1-FINAL                                Start: 06/30/2003 *
+ * ===================                          Last change: 11/27/2004 *
  *                                                                      *
  * -------------------------------------------------------------------- *
  * File              : admins_functions.php                             *
@@ -139,14 +139,14 @@ LIMIT 1",
                        list($adminId) = SQL_FETCHROW($result);
 
                        // Rewrite email address to contact link
-                       $email = "{?URL?}/modules.php?module=".$mod."&amp;what=admins_contct&amp;admin=".bigintval($adminId);
+                       $email = '{%url=modules.php?module=' . $mod . '&amp;what=admins_contct&amp;admin=' . bigintval($adminId) . '%}';
                } // END - if
 
                // Free memory
                SQL_FREERESULT($result);
        } elseif ((is_int($email)) && ($email > 0)) {
                // Direct id given
-               $email = "{?URL?}/modules.php?module=".$mod."&amp;what=admins_contct&amp;admin=".bigintval($email);
+               $email = '{%url=modules.php?module=' . $mod . '&amp;what=admins_contct&amp;admin=' . bigintval($email) . '%}';
        }
 
        // Return rewritten (?) email address
@@ -399,12 +399,12 @@ function FILTER_ADD_EXTRA_SQL_DATA ($add = '') {
 
 // Sends out mail to all administrators
 // IMPORTANT: Please use SEND_ADMIN_NOTIFCATION() for now!
-function sendAdminsEmails ($subj, $template, $content, $UID) {
+function sendAdminsEmails ($subj, $template, $content, $userid) {
        // Trim template name
        $template = trim($template);
 
        // Load email template
-       $message = loadEmailTemplate($template, $content, $UID);
+       $message = loadEmailTemplate($template, $content, $userid);
 
        // Check which admin shall receive this mail
        $result = SQL_QUERY_ESC("SELECT `admin_id` FROM `{?_MYSQL_PREFIX?}_admins_mails` WHERE `mail_template`='%s' ORDER BY `admin_id` ASC",
@@ -432,13 +432,13 @@ function sendAdminsEmails ($subj, $template, $content, $UID) {
                if ($adminId == '-1') {
                        if (isExtensionActive('events')) {
                                // Add line to user events
-                               EVENTS_ADD_LINE($subj, $message, $UID);
+                               EVENTS_ADD_LINE($subj, $message, $userid);
                        } else {
                                // Log error for debug
-                               logDebugMessage(__FUNCTION__, __LINE__, sprintf("Extension 'events' missing: tpl=%s,subj=%s,UID=%s",
+                               logDebugMessage(__FUNCTION__, __LINE__, sprintf("Extension 'events' missing: tpl=%s,subj=%s,userid=%s",
                                        $template,
                                        $subj,
-                                       $UID
+                                       $userid
                                ));
                        }
                } elseif ($adminId == '0') {