]> git.mxchange.org Git - mailer.git/blobdiff - inc/template-functions.php
Code cleanup, more usage of API functions
[mailer.git] / inc / template-functions.php
index 931d18d2c440c9053ae950ccdd7d4725c2d3800f..4da8ef31b200524115d5b34bb1e23de321738988 100644 (file)
@@ -14,8 +14,6 @@
  * $Date::                                                            $ *
  * $Tag:: 0.2.1-FINAL                                                 $ *
  * $Author::                                                          $ *
- * Needs to be in all Files and every File needs "svn propset           *
- * svn:keywords Date Revision" (autoprobset!) at least!!!!!!            *
  * -------------------------------------------------------------------- *
  * Copyright (c) 2003 - 2009 by Roland Haeder                           *
  * Copyright (c) 2009, 2010 by Mailer Developer Team                    *
@@ -278,7 +276,6 @@ function loadTemplate ($template, $return = false, $content = array()) {
 
                // Init some data
                $ret = '';
-               if (empty($GLOBALS['refid'])) $GLOBALS['refid'] = '0';
 
                // Base directory
                $basePath = sprintf("%stemplates/%s/html/", getPath(), getLanguage());
@@ -432,7 +429,7 @@ function loadEmailTemplate ($template, $content = array(), $userid = '0') {
                        $content['expiration'] = '{--MAIL_WILL_NEVER_EXPIRE--}';
                } elseif (isConfigEntrySet('auto_purge')) {
                        // Create nice date string
-                       $content['expiration'] = createFancyTime(getAutoPurge());
+                       $content['expiration'] = '{%pipe,getAutoPurge,createFancyTime%}';
                } else {
                        // Missing entry
                        $content['expiration'] = '{--MAIL_NO_CONFIG_AUTO_PURGE--}';
@@ -1045,6 +1042,9 @@ function generateMemberAdminActionLinks ($userid) {
                if (($tar == 'lock_user') && ($status == 'LOCKED')) {
                        // Locked accounts shall be unlocked
                        $OUT .= 'UNLOCK_USER';
+               } elseif ($tar == 'del_user') {
+                       // @TODO Deprecate this thing
+                       $OUT .= 'DELETE_USER';
                } else {
                        // All other status is fine
                        $OUT .= strtoupper($tar);
@@ -1053,6 +1053,9 @@ function generateMemberAdminActionLinks ($userid) {
                if (($tar == 'lock_user') && ($status == 'LOCKED')) {
                        // Locked accounts shall be unlocked
                        $OUT .= 'UNLOCK_USER';
+               } elseif ($tar == 'del_user') {
+                       // @TODO Deprecate this thing
+                       $OUT .= 'DELETE_USER';
                } else {
                        // All other status is fine
                        $OUT .= strtoupper($tar);