- // Prepare subject
- if (defined($constantName)) {
- $subject = constant($constantName);
- } else {
- ADD_FATAL(MEMBER_SURFBAR_NOTIFY_SUBJECT_404, $constantName);
- }
+ // Is the subject line there?
+ if ((substr($subject, 0, 1) == "!") && (substr($subject, -1, 1) == "!")) {
+ // Set default subject if following eval() wents wrong
+ $subject = getMessage('MEMBER_SURFBAR_NOTIFY_DEFAULT_SUBJECT');
+ } // END - if
+
+ // Translate some data if present
+ if (isset($content['status'])) $content['status'] = SURFBAR_TRANSLATE_STATUS($content['status']);
+ if (isset($content['registered'])) $content['registered'] = MAKE_DATETIME($content['registered'], "2");
+ if (isset($content['last_locked'])) $content['last_locked'] = MAKE_DATETIME($content['last_locked'], "2");
+ if (isset($content['views_total'])) $content['views_total'] = TRANSLATE_COMMA($content['views_total']);
+ if (isset($content['views_allowed'])) $content['views_allowed'] = TRANSLATE_COMMA($content['views_allowed']);
+ if (isset($content['views_max'])) $content['views_max'] = TRANSLATE_COMMA($content['views_max']);