From 89c30a00a71988c8db632f8f3cc94ed241bdaa1f Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Sun, 01 Jan 2012 07:26:08 -0500
Subject: [PATCH] - Don't load jqueryui plugin, it's required now by default - Move datepicker's date format setting to the plugin
---
program/include/rcube_imap.php | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/program/include/rcube_imap.php b/program/include/rcube_imap.php
index 3552010..2a2f203 100644
--- a/program/include/rcube_imap.php
+++ b/program/include/rcube_imap.php
@@ -1400,6 +1400,7 @@
* @param string $charset Search charset
* @param string $sort_field Header field to sort by
* @access public
+ * @todo: Search criteria should be provided in non-IMAP format, eg. array
*/
function search($mailbox='', $str='ALL', $charset=NULL, $sort_field=NULL)
{
@@ -1469,7 +1470,7 @@
// Error, try with US-ASCII (some servers may support only US-ASCII)
if ($messages->isError() && $charset && $charset != 'US-ASCII')
$messages = $this->conn->search($mailbox,
- 'CHARSET US-ASCII ' . $this->convert_criteria($criteria, $charset), true);
+ $this->convert_criteria($criteria, $charset), true);
$this->search_sorted = false;
@@ -1520,9 +1521,9 @@
$string_offset = $m[1] + strlen($m[0]) + 4; // {}\r\n
$string = substr($str, $string_offset - 1, $m[0]);
$string = rcube_charset_convert($string, $charset, $dest_charset);
- if (!$string)
+ if ($string === false)
continue;
- $res .= sprintf("%s{%d}\r\n%s", substr($str, $last, $m[1] - $last - 1), strlen($string), $string);
+ $res .= substr($str, $last, $m[1] - $last - 1) . rcube_imap_generic::escape($string);
$last = $m[0] + $string_offset - 1;
}
if ($last < strlen($str))
--
Gitblit v1.9.1