From e5d60d69d4108a0e62270548117773244ca1905e Mon Sep 17 00:00:00 2001 From: alecpl Date: Wed, 9 Dec 2009 08:18:47 +0000 Subject: - Use built-in json_encode() for proper JSON format in AJAX replies (and compat. with jQuery 1.4) --- program/steps/mail/compose.inc | 2 +- program/steps/mail/func.inc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'program/steps/mail') diff --git a/program/steps/mail/compose.inc b/program/steps/mail/compose.inc index a441e00b6..999242c1a 100644 --- a/program/steps/mail/compose.inc +++ b/program/steps/mail/compose.inc @@ -506,7 +506,7 @@ function rcmail_compose_body($attrib) JQ(Q(rcube_label('close'))), JQ(Q(rcube_label('revertto'))), JQ(Q(rcube_label('nospellerrors'))), - json_serialize($spellcheck_langs), + json_encode($spellcheck_langs), $lang, $attrib['id'], JS_OBJECT_NAME), 'foot'); diff --git a/program/steps/mail/func.inc b/program/steps/mail/func.inc index b3016ee2a..6b2ce0907 100644 --- a/program/steps/mail/func.inc +++ b/program/steps/mail/func.inc @@ -522,7 +522,7 @@ function rcmail_quota_display($attrib) if (is_array($quota)) { $OUTPUT->add_script('$(document).ready(function(){ - rcmail.set_quota('.json_serialize($quota).')});', 'foot'); + rcmail.set_quota('.json_encode($quota).')});', 'foot'); $quota = ''; } -- cgit v1.2.3