]> git.mxchange.org Git - mailer.git/blobdiff - inc/template-functions.php
is only supported in email templates and not required in member login area
[mailer.git] / inc / template-functions.php
index 37b557fb741e2579b534345888789b4deabab528..057ec6a052a90b93d8e82ccef64f43ef2a66c851 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                    *
@@ -326,7 +324,7 @@ function loadTemplate ($template, $return = false, $content = array()) {
                } elseif ((isAdmin()) || ((isInstalling()) && (!isInstalled()))) {
                        // Only admins shall see this warning or when installation mode is active
                        $ret = '<div class="para">
-       <span class="guest_failed">{--TEMPLATE_404--}</span>
+       <span class="notice">{--TEMPLATE_404--}</span>
 </div>
 <div class="para">
        (' . $template . ')
@@ -654,7 +652,7 @@ function compileRawCode ($code, $simple = false, $constants = true, $full = true
 }
 
 //
-function addSelectionBox ($type, $default, $prefix = '', $id = '0', $class = 'register_select') {
+function addSelectionBox ($type, $default, $prefix = '', $id = '0', $class = 'form_select') {
        $OUT = '';
 
        if ($type == 'yn') {
@@ -1040,19 +1038,25 @@ function generateMemberAdminActionLinks ($userid) {
        $OUT = '[';
 
        foreach ($targetArray as $tar) {
-               $OUT .= '<span class="admin_user_link"><a href="{%url=modules.php?module=admin&amp;what=' . $tar . '&amp;userid=' . $userid . '%}" title="{--ADMIN_LINK_';
+               $OUT .= '<span class="admin_user_link"><a href="{%url=modules.php?module=admin&amp;what=' . $tar . '&amp;userid=' . $userid . '%}" title="{--ADMIN_USER_ACTION_LINK_';
                //* DEBUG: */ debugOutput('*' . $tar.'/' . $status.'*');
                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);
                }
-               $OUT .= '_TITLE--}">{--ADMIN_';
+               $OUT .= '_TITLE--}">{--ADMIN_USER_ACTION_LINK_';
                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);
@@ -1524,21 +1528,21 @@ function sendModeMails ($mod, $modes) {
                                        $sub_mem = '{--MEMBER_CHANGED_DATA--}';
 
                                        // Output success message
-                                       $content = '<span class="member_done">{--MEMBER_MYDATA_MAIL_SENT--}</span>';
+                                       $content = '<span class="message">{--MEMBER_MYDATA_MAIL_SENT--}</span>';
                                        break;
 
                                default: // Unsupported module!
                                        logDebugMessage(__FUNCTION__, __LINE__, sprintf("Unsupported module %s detected.", $mod));
-                                       $content = '<span class="member_failed">{--UNKNOWN_MODULE--}</span>';
+                                       $content = '<span class="notice">{--UNKNOWN_MODULE--}</span>';
                                        break;
                        } // END - switch
                } else {
                        // Passwords mismatch
-                       $content = '<span class="member_failed">{--MEMBER_PASSWORD_ERROR--}</span>';
+                       $content = '<span class="notice">{--MEMBER_PASSWORD_ERROR--}</span>';
                }
        } else {
                // Could not load profile
-               $content = '<span class="member_failed">{--MEMBER_CANNOT_LOAD_PROFILE--}</span>';
+               $content = '<span class="notice">{--MEMBER_CANNOT_LOAD_PROFILE--}</span>';
        }
 
        // Send email to user if required
@@ -1557,7 +1561,7 @@ function sendModeMails ($mod, $modes) {
                        $content = '{--CANNOT_SEND_ADMIN_MAILS--}';
                } else {
                        // No mail to admin
-                       $content = '<span class="member_done">{--MEMBER_MYDATA_MAIL_SENT--}</span>';
+                       $content = '<span class="message">{--MEMBER_MYDATA_MAIL_SENT--}</span>';
                }
        } // END - if
 
@@ -1568,7 +1572,7 @@ function sendModeMails ($mod, $modes) {
 // Generates a 'selection box' from given array
 function generateSelectionBoxFromArray ($options, $name, $optionValue, $optionContent = '', $extraName = '') {
        // Start the output
-       $OUT = '<select name="' . $name . '" size="1" class="admin_select">
+       $OUT = '<select name="' . $name . '" size="1" class="form_select">
 <option value="X" disabled="disabled">{--PLEASE_SELECT--}</option>';
 
        // Walk through all options
@@ -1704,7 +1708,7 @@ function doTemplateExtensionRegistrationLink ($template, $dummy, $ext_name) {
        // Is the given extension non-productive?
        if (!isExtensionProductive($ext_name)) {
                // Non-productive code
-               $OUT = '<em style="cursor:help" class="admin_note" title="{%message,ADMIN_EXTENSION_IS_NON_PRODUCTIVE_LINK_TITLE=' . $ext_name . '%}">{--ADMIN_EXTENSION_IS_NON_PRODUCTIVE_LINK--}</em>';
+               $OUT = '<em style="cursor:help" class="notice" title="{%message,ADMIN_EXTENSION_IS_NON_PRODUCTIVE_LINK_TITLE=' . $ext_name . '%}">{--ADMIN_EXTENSION_IS_NON_PRODUCTIVE_LINK--}</em>';
        } // END - if
 
        // Return code