Changeset 2717f9f in github
- Timestamp:
- Dec 11, 2009 11:53:54 AM (3 years ago)
- Branches:
- master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.6, release-0.7, release-0.8
- Children:
- 7a05909
- Parents:
- f47e2dc
- Location:
- program
- Files:
-
- 6 edited
-
include/rcube_json_output.php (modified) (2 diffs)
-
include/rcube_shared.inc (modified) (2 diffs)
-
include/rcube_template.php (modified) (1 diff)
-
steps/mail/compose.inc (modified) (1 diff)
-
steps/mail/func.inc (modified) (2 diffs)
-
steps/mail/headers.inc (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
program/include/rcube_json_output.php
re5d60d6 r2717f9f 240 240 $response['callbacks'] = $this->callbacks; 241 241 242 echo json_ encode($response);242 echo json_serialize($response); 243 243 } 244 244 … … 252 252 { 253 253 $out = ''; 254 254 255 255 foreach ($this->commands as $i => $args) { 256 256 $method = array_shift($args); 257 257 foreach ($args as $i => $arg) { 258 $args[$i] = json_ encode($arg);258 $args[$i] = json_serialize($arg); 259 259 } 260 260 -
program/include/rcube_shared.inc
re5d60d6 r2717f9f 511 511 if (!is_string($input) || $input == '') 512 512 return $input; 513 513 514 514 // iconv/mbstring are much faster (especially with long strings) 515 515 if (function_exists('mb_convert_encoding') && ($res = mb_convert_encoding($input, 'UTF8', 'UTF8'))) … … 564 564 } 565 565 566 567 /** 568 * Convert a variable into a javascript object notation 569 * 570 * @param mixed Input value 571 * @return string Serialized JSON string 572 */ 573 function json_serialize($input) 574 { 575 $input = rc_utf8_clean($input); 576 577 return json_encode($input); 578 } 579 580 566 581 /** 567 582 * Explode quoted string -
program/include/rcube_template.php
re5d60d6 r2717f9f 415 415 $out = ''; 416 416 if (!$this->framed && !empty($this->js_env)) { 417 $out .= JS_OBJECT_NAME . '.set_env('.json_ encode($this->js_env).");\n";417 $out .= JS_OBJECT_NAME . '.set_env('.json_serialize($this->js_env).");\n"; 418 418 } 419 419 foreach ($this->js_commands as $i => $args) { 420 420 $method = array_shift($args); 421 421 foreach ($args as $i => $arg) { 422 $args[$i] = json_ encode($arg);422 $args[$i] = json_serialize($arg); 423 423 } 424 424 $parent = $this->framed || preg_match('/^parent\./', $method); -
program/steps/mail/compose.inc
r8abe548 r2717f9f 506 506 JQ(Q(rcube_label('revertto'))), 507 507 JQ(Q(rcube_label('nospellerrors'))), 508 json_ encode($spellcheck_langs),508 json_serialize($spellcheck_langs), 509 509 $lang, 510 510 $attrib['id'], -
program/steps/mail/func.inc
rf96ffde r2717f9f 459 459 $a_msg_flags['flagged'] = 1; 460 460 461 if ($browser->ie)462 $a_msg_cols = rc_utf8_clean($a_msg_cols);463 464 461 $OUTPUT->command('add_message_row', 465 462 $header->uid, … … 523 520 if (is_array($quota)) { 524 521 $OUTPUT->add_script('$(document).ready(function(){ 525 rcmail.set_quota('.json_ encode($quota).')});', 'foot');522 rcmail.set_quota('.json_serialize($quota).')});', 'foot'); 526 523 $quota = ''; 527 524 } -
program/steps/mail/headers.inc
r1a00f13 r2717f9f 25 25 if ($source) 26 26 { 27 $browser = new rcube_browser;28 29 if ($browser->ie)30 $source = rc_utf8_clean($source);31 32 27 $source = htmlspecialchars(trim($source)); 33 28 $source = preg_replace('/\t/', ' ', $source);
Note: See TracChangeset
for help on using the changeset viewer.
