]> git.mxchange.org Git - mailer.git/blobdiff - inc/functions.php
Some theme fixes, debug system now forced (true)
[mailer.git] / inc / functions.php
index cfbd66538429ce16230912500ad6b680bf9f6607..177886ad3aaf33e96f46aaf77563b558733e8368 100644 (file)
@@ -132,7 +132,7 @@ function OUTPUT_HTML($HTML, $NEW_LINE = true) {
 
                default:
                        // Huh, something goes wrong or maybe you have edited config.php ???
 
                default:
                        // Huh, something goes wrong or maybe you have edited config.php ???
-                       DEBUG_LOG(__FILE__, __LINE__, sprintf("Invalid renderer %s detected.", OUTPUT_MODE));
+                       DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("Invalid renderer %s detected.", OUTPUT_MODE));
                        MXCHANGE_DIE("<STRONG>".FATAL_ERROR.":</STRONG> ".LANG_NO_RENDER_DIRECT);
                        break;
                }
                        MXCHANGE_DIE("<STRONG>".FATAL_ERROR.":</STRONG> ".LANG_NO_RENDER_DIRECT);
                        break;
                }
@@ -259,6 +259,7 @@ function LOAD_TEMPLATE($template, $return=false, $content=array()) {
 
                        // Translate gender
                        $gender = TRANSLATE_GENDER($gender);
 
                        // Translate gender
                        $gender = TRANSLATE_GENDER($gender);
+                       DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("DEPRECATION-WARNING: content is not array (%s).", gettype($content)));
                }
 
                // Free result
                }
 
                // Free result
@@ -569,7 +570,7 @@ function MAKE_DATETIME ($time, $mode="0")
                        case "2": $ret = date("d.m.Y|H:i", $time); break;
                        case "3": $ret = date("d.m.Y", $time); break;
                        default:
                        case "2": $ret = date("d.m.Y|H:i", $time); break;
                        case "3": $ret = date("d.m.Y", $time); break;
                        default:
-                               DEBUG_LOG(__FILE__, __LINE__, sprintf("Invalid date mode %s detected.", $mode));
+                               DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("Invalid date mode %s detected.", $mode));
                                break;
                }
                break;
                                break;
                }
                break;
@@ -581,7 +582,7 @@ function MAKE_DATETIME ($time, $mode="0")
                        case "2": $ret = date("y-m-d|H:i", $time); break;
                        case "3": $ret = date("y-m-d", $time); break;
                        default:
                        case "2": $ret = date("y-m-d|H:i", $time); break;
                        case "3": $ret = date("y-m-d", $time); break;
                        default:
-                               DEBUG_LOG(__FILE__, __LINE__, sprintf("Invalid date mode %s detected.", $mode));
+                               DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("Invalid date mode %s detected.", $mode));
                                break;
                }
        }
                                break;
                }
        }
@@ -703,7 +704,7 @@ function TRANSLATE_STATUS($status) {
                break;
 
        default:
                break;
 
        default:
-               DEBUG_LOG(__FILE__, __LINE__, sprintf("Unknown status %s detected.", $status));
+               DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("Unknown status %s detected.", $status));
                $ret = UNKNOWN_STATUS_1.$status.UNKNOWN_STATUS_2;
                break;
        }
                $ret = UNKNOWN_STATUS_1.$status.UNKNOWN_STATUS_2;
                break;
        }
@@ -1755,7 +1756,7 @@ function POST_URL ($script, $postData) {
        // Is postData an array?
        if (!is_array($postData)) {
                // Abort here
        // Is postData an array?
        if (!is_array($postData)) {
                // Abort here
-               DEBUG_LOG(__FILE__, __LINE__, sprintf("postData is not an array. Type: %s", gettype($postData)));
+               DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("postData is not an array. Type: %s", gettype($postData)));
                return array("", "", "");
        } // END - if
 
                return array("", "", "");
        } // END - if
 
@@ -2384,7 +2385,7 @@ function merge_array ($array1, $array2) {
        die("</pre>");
 }
 // Debug message logger
        die("</pre>");
 }
 // Debug message logger
-function DEBUG_LOG ($file, $line, $message, $force=false) {
+function DEBUG_LOG ($file, $line, $message, $force=true) {
        // Is debug mode enabled?
        if ((isBooleanConstantAndTrue('DEBUG_MODE')) || ($force)) {
                // Log this message away
        // Is debug mode enabled?
        if ((isBooleanConstantAndTrue('DEBUG_MODE')) || ($force)) {
                // Log this message away