From 9b624ba1493786bf2a03a4bb5f6faa173736c899 Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Thu, 24 Feb 2011 07:12:09 -0500
Subject: [PATCH] - Merge fixes from trunk

---
 program/include/main.inc |   15 +++++++++++++--
 1 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/program/include/main.inc b/program/include/main.inc
index 7be7488..3ac26dc 100644
--- a/program/include/main.inc
+++ b/program/include/main.inc
@@ -1067,7 +1067,18 @@
       $out .= date($format{$i}, $timestamp);
   }
 
-  return $today ? (rcube_label('today') . ' ' . $out) : $out;
+  if ($today) {
+    $label = rcube_label('today');
+    // replcae $ character with "Today" label (#1486120)
+    if (strpos($out, '$') !== false) {
+      $out = preg_replace('/\$/', $label, $out, 1);
+    }
+    else {
+      $out = $label . ' ' . $out;
+    }
+  }
+
+  return $out;
 }
 
 
@@ -1685,7 +1696,7 @@
 {
   global $RCMAIL, $CONFIG;
 
-  $hook = $RCMAIL->plugins->exec_hook('hmtl_editor', array('mode' => $mode));
+  $hook = $RCMAIL->plugins->exec_hook('html_editor', array('mode' => $mode));
 
   if ($hook['abort'])
     return;  

--
Gitblit v1.9.1