/PHP-7.2/ |
H A D | NEWS | 1502 json_encode and json_decode to ignore or replace invalid UTF-8 byte 2784 . Implemented earlier return when json_encode fails, fixes bugs #68992 2786 error, json_encode can eat up all system memory). (Jakub Zelenka) 2791 json_encode options and added JSON_UNESCAPED_LINE_TERMINATORS to restore
|
H A D | UPGRADING | 136 json_encode() and json_decode() to ignore and replace invalid UTF-8 byte
|
/PHP-7.2/ext/json/ |
H A D | json.c | 35 static PHP_FUNCTION(json_encode); 67 PHP_FE(json_encode, arginfo_json_encode) 228 static PHP_FUNCTION(json_encode) in PHP_FUNCTION() argument
|
/PHP-7.2/ext/json/tests/ |
H A D | 002.phpt | 2 json_encode() tests 8 var_dump(json_encode("")); 9 var_dump(json_encode(NULL)); 10 var_dump(json_encode(TRUE)); 12 var_dump(json_encode(array(""=>""))); 13 var_dump(json_encode(array(array(1)))); 14 var_dump(json_encode(array())); 16 var_dump(json_encode(array(""=>""), JSON_FORCE_OBJECT)); 18 var_dump(json_encode(array(), JSON_FORCE_OBJECT)); 20 var_dump(json_encode(1)); [all …]
|
H A D | 003.phpt | 2 json_encode() & endless loop - 1 15 var_dump(json_encode($a)); 20 var_dump(json_encode($a, JSON_PARTIAL_OUTPUT_ON_ERROR));
|
H A D | 004.phpt | 2 json_encode() & endless loop - 2 15 var_dump(json_encode($a)); 20 var_dump(json_encode($a, JSON_PARTIAL_OUTPUT_ON_ERROR));
|
H A D | 005.phpt | 2 json_encode() & endless loop - 3 12 var_dump(json_encode($a));
|
H A D | 006.phpt | 2 json_encode() & extended encoding 9 echo "Normal: ", json_encode($a), "\n"; 10 echo "Tags: ", json_encode($a, JSON_HEX_TAG), "\n"; 11 echo "Apos: ", json_encode($a, JSON_HEX_APOS), "\n"; 12 echo "Quot: ", json_encode($a, JSON_HEX_QUOT), "\n"; 13 echo "Amp: ", json_encode($a, JSON_HEX_AMP), "\n"; 14 echo "All: ", json_encode($a, JSON_HEX_TAG|JSON_HEX_APOS|JSON_HEX_QUOT|JSON_HEX_AMP), "\n";
|
H A D | bug40503.phpt | 2 Bug #40503 (json_encode() value corruption on 32bit systems with overflown values) 14 json_test_show_eq("$value", json_encode($value)); 16 json_test_show_eq("$value", json_encode($value));
|
H A D | bug41034.phpt | 2 Bug #41034 (json_encode() ignores null byte started keys in arrays) 7 echo json_encode(array(0, "\0ab"=>1, "\0null-prefixed value"));
|
H A D | bug41067.phpt | 2 Bug #41067 (json_encode() problem with UTF-16 input) 11 $json = json_encode($array);
|
H A D | bug41567.phpt | 2 Bug #41567 (json_encode() double conversion is inconsistent with PHP) 10 $a = json_encode(123456789.12345);
|
H A D | bug42090.phpt | 12 json_encode('"'), 13 json_decode(json_encode('"')), 14 json_decode(json_encode('""'))
|
H A D | bug42785.phpt | 17 var_dump(json_encode($foo)); 23 var_dump(json_encode($bar1));
|
H A D | bug43941.phpt | 2 Bug #43941 (json_encode() invalid UTF-8) 8 var_dump(json_encode("abc")); 9 var_dump(json_encode("ab\xE0")); 10 var_dump(json_encode("ab\xE0", JSON_PARTIAL_OUTPUT_ON_ERROR)); 11 var_dump(json_encode(array("ab\xE0", "ab\xE0c", "abc"), JSON_PARTIAL_OUTPUT_ON_ERROR));
|
H A D | bug46215.phpt | 2 Bug #46215 (json_encode mutates its parameter and has some class-specific state) 13 $x = json_encode($a);
|
H A D | bug46944.phpt | 2 Bug #46944 (json_encode() doesn't handle 3 byte utf8 correctly) 12 echo json_encode($string) . "\n";
|
H A D | bug50224.phpt | 2 bug #50224 (json_encode() does not always encode a float as a float) 10 var_dump(json_encode(12.3, JSON_PRESERVE_ZERO_FRACTION)); 11 var_dump(json_encode(12, JSON_PRESERVE_ZERO_FRACTION)); 12 var_dump(json_encode(12.0, JSON_PRESERVE_ZERO_FRACTION)); 13 var_dump(json_encode(0.0, JSON_PRESERVE_ZERO_FRACTION)); 14 var_dump(json_encode(array(12, 12.0, 12.3), JSON_PRESERVE_ZERO_FRACTION)); 19 var_dump(json_decode(json_encode(12.3, JSON_PRESERVE_ZERO_FRACTION))); 20 var_dump(json_decode(json_encode(12, JSON_PRESERVE_ZERO_FRACTION))); 21 var_dump(json_decode(json_encode(12.0, JSON_PRESERVE_ZERO_FRACTION))); 22 var_dump(json_decode(json_encode(0.0, JSON_PRESERVE_ZERO_FRACTION))); [all …]
|
H A D | bug53946.phpt | 2 bug #53946 (json_encode() with JSON_UNESCAPED_UNICODE) 7 var_dump(json_encode("latin 1234 -/ russian мама мыла раму specialchars \x02 \x08 \n U+1D11… 8 var_dump(json_encode("latin 1234 -/ russian мама мыла раму specialchars \x02 \x08 \n U+1D11… 9 var_dump(json_encode("ab\xE0")); 10 var_dump(json_encode("ab\xE0", JSON_UNESCAPED_UNICODE));
|
H A D | bug54058.phpt | 10 json_encode($bad_utf8); 15 json_encode($a); 21 json_encode($b); 28 json_encode($c);
|
H A D | bug55543.phpt | 2 Bug #55543 (json_encode() with JSON_NUMERIC_CHECK & numeric string properties) 10 var_dump(json_encode($a, JSON_NUMERIC_CHECK));
|
H A D | bug61537.phpt | 2 Bug #61537 (json_encode() incorrectly truncates/discards information) 9 var_dump(json_encode($invalid_utf8)); 12 var_dump(json_encode($invalid_utf8, JSON_PARTIAL_OUTPUT_ON_ERROR)); 19 var_dump(json_encode($invalid_utf8)); 22 var_dump(json_encode($invalid_utf8, JSON_PARTIAL_OUTPUT_ON_ERROR));
|
H A D | bug61978.phpt | 32 var_dump(json_encode($obj1, JSON_PARTIAL_OUTPUT_ON_ERROR)); 37 var_dump(json_encode($obj2, JSON_PARTIAL_OUTPUT_ON_ERROR));
|
H A D | bug62369.phpt | 2 FR #62369 (Segfault on json_encode(deeply_nested_array) 13 json_encode($array, 0, 551); 23 json_encode($array, 0, 540);
|
H A D | bug64695.phpt | 8 var_dump(json_encode($t, JSON_NUMERIC_CHECK));
|