* -------------------------------------------------------------------- *
* File : functions.php *
* -------------------------------------------------------------------- *
- * Short description : Many non-MySQL functions (also file access) *
+ * Short description : Many non-database functions (also file access) *
* -------------------------------------------------------------------- *
- * Kurzbeschreibung : Viele Nicht-MySQL-Funktionen (auch Dateizugriff) *
+ * Kurzbeschreibung : Viele Nicht-Datenbank-Funktionen *
* -------------------------------------------------------------------- *
* $Revision:: $ *
* $Date:: $ *
// Get data array with years/months/weeks/days/...
$data = createTimeSelections($stamp, '', '', '', true);
$ret = '';
- foreach($data as $k => $v) {
+ foreach ($data as $k => $v) {
if ($v > 0) {
// Value is greater than 0 "eval" data to return string
$ret .= ', ' . $v . ' {--_' . strtoupper($k) . '--}';
// An error was detected!
return false;
}
+
// Send notification to admin
-function sendAdminNotification ($subject, $templateName, $content=array(), $userid = '0') {
+function sendAdminNotification ($subject, $templateName, $content = array(), $userid = '0') {
if ((isExtensionInstalledAndNewer('admins', '0.4.1')) && (function_exists('sendAdminsEmails'))) {
// Send new way
+ /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'admins=Y,subject=' . $subject . ',templateName=' . $templateName);
sendAdminsEmails($subject, $templateName, $content, $userid);
} else {
- // Send out out-dated way
+ // Send out-dated way
+ /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'admins=N,subject=' . $subject . ',templateName=' . $templateName);
$message = loadEmailTemplate($templateName, $content, $userid);
sendAdminEmails($subject, $message);
}
$message = str_replace("\r", '', str_replace("\n", '', $message));
// Log this message away
- appendLineToFile(getCachePath() . 'debug.log', generateDateTime(time(), '4') . '|' . getModule(false) . '|' . basename($funcFile) . '|' . $line . '|' . $message);
+ appendLineToFile(getPath() . getCachePath() . 'debug.log', generateDateTime(time(), '4') . '|' . getModule(false) . '|' . basename($funcFile) . '|' . $line . '|' . $message);
} // END - if
}