Home
last modified time | relevance | path

Searched refs:mb_convert_encoding (Results 1 – 25 of 36) sorted by relevance

12

/PHP-7.2/ext/mbstring/tests/
H A Dbug48645.phpt2 Bug #48645 (mb_convert_encoding() doesn't understand hexadecimal html-entities)
7 var_dump(bin2hex(mb_convert_encoding("�", "UTF-8", "HTML-ENTITIES")));
8 var_dump(bin2hex(mb_convert_encoding("", "UTF-8", "HTML-ENTITIES")));
9 var_dump(bin2hex(mb_convert_encoding("", "UTF-8", "HTML-ENTITIES")));
10 var_dump(bin2hex(mb_convert_encoding("", "UTF-8", "HTML-ENTITIES")));
11 var_dump(bin2hex(mb_convert_encoding("", "UTF-8", "HTML-ENTITIES")));
12 var_dump(bin2hex(mb_convert_encoding("", "UTF-8", "HTML-ENTITIES")));
13 var_dump(bin2hex(mb_convert_encoding("", "UTF-8", "HTML-ENTITIES")));
14 var_dump(bin2hex(mb_convert_encoding("", "UTF-8", "HTML-ENTITIES")));
15 var_dump(bin2hex(mb_convert_encoding("", "UTF-8", "HTML-ENTITIES")));
[all …]
H A Dpictogram1.phpt10 var_dump(bin2hex(mb_convert_encoding("\xf8\x9f", "UCS-4BE", "SJIS-Mobile#DOCOMO")));
11 var_dump(bin2hex(mb_convert_encoding("\xf6\x60", "UCS-4BE", "SJIS-Mobile#KDDI")));
12 var_dump(bin2hex(mb_convert_encoding("\xf9\x8b", "UCS-4BE", "SJIS-Mobile#SOFTBANK")));
14 var_dump(bin2hex(mb_convert_encoding("\xf9\xe6", "UCS-4BE", "SJIS-Mobile#DOCOMO")));
15 var_dump(bin2hex(mb_convert_encoding("\xf6\xec", "UCS-4BE", "SJIS-Mobile#KDDI")));
16 var_dump(bin2hex(mb_convert_encoding("\xf7\x50", "UCS-4BE", "SJIS-Mobile#SOFTBANK")));
18 var_dump(bin2hex(mb_convert_encoding("\xf9\x85", "UCS-4BE", "SJIS-Mobile#DOCOMO")));
19 var_dump(bin2hex(mb_convert_encoding("\xf4\x89", "UCS-4BE", "SJIS-Mobile#KDDI")));
20 var_dump(bin2hex(mb_convert_encoding("\xf7\xb0", "UCS-4BE", "SJIS-Mobile#SOFTBANK")));
22 var_dump(bin2hex(mb_convert_encoding("\xf3\xd2", "UCS-4BE", "SJIS-Mobile#KDDI")));
[all …]
H A Dmb_convert_encoding_array2.phpt2 Test mb_convert_encoding() function : Circular references
6 function_exists('mb_convert_encoding') or die("skip mb_convert_encoding() is not available in this …
16 * Test basic functionality of mb_convert_encoding()
19 echo "*** Testing mb_convert_encoding() : Circular references ***\n";
55 var_dump(base64_encode_array(mb_convert_encoding($sjis_string, 'JIS', 'SJIS')));
57 var_dump(base64_encode_array(mb_convert_encoding($utf8_string, 'JIS', 'UTF-8')));
64 var_dump(base64_encode_array(mb_convert_encoding($jis_string, 'EUC-JP', 'JIS')));
71 var_dump(base64_encode_array(mb_convert_encoding($jis_string, 'SJIS', 'JIS')));
73 var_dump(base64_encode_array(mb_convert_encoding($utf8_string, 'SJIS', 'UTF-8')));
80 var_dump(base64_encode_array(mb_convert_encoding($jis_string, 'UTF-8', 'JIS')));
[all …]
H A Dmb_convert_encoding_variation1.phpt6 function_exists('mb_convert_encoding') or die("skip mb_convert_encoding() is not available in this …
20 echo "*** Testing mb_convert_encoding() : usage variations ***\n";
107 *** Testing mb_convert_encoding() : usage variations ***
111 Warning: mb_convert_encoding(): Unknown encoding "0" in %s on line %d
116 Warning: mb_convert_encoding(): Unknown encoding "1" in %s on line %d
121 Warning: mb_convert_encoding(): Unknown encoding "12345" in %s on line %d
126 Warning: mb_convert_encoding(): Unknown encoding "-2345" in %s on line %d
131 Warning: mb_convert_encoding(): Unknown encoding "10.5" in %s on line %d
151 Warning: mb_convert_encoding(): Unknown encoding "0.5" in %s on line %d
162 Warning: mb_convert_encoding(): Unknown encoding "1" in %s on line %d
[all …]
H A Dmb_convert_encoding_basic.phpt2 Test mb_convert_encoding() function : basic functionality
6 function_exists('mb_convert_encoding') or die("skip mb_convert_encoding() is not available in this …
16 * Test basic functionality of mb_convert_encoding()
19 echo "*** Testing mb_convert_encoding() : basic functionality ***\n";
31 var_dump(base64_encode(mb_convert_encoding($sjis_string, 'JIS', 'SJIS')));
33 var_dump(base64_encode(mb_convert_encoding($utf8_string, 'JIS', 'UTF-8')));
40 var_dump(base64_encode(mb_convert_encoding($jis_string, 'EUC-JP', 'JIS')));
47 var_dump(base64_encode(mb_convert_encoding($jis_string, 'SJIS', 'JIS')));
49 var_dump(base64_encode(mb_convert_encoding($utf8_string, 'SJIS', 'UTF-8')));
56 var_dump(base64_encode(mb_convert_encoding($jis_string, 'UTF-8', 'JIS')));
[all …]
H A Dmb_convert_encoding_stateful.phpt2 mb_convert_encoding() with stateful encodings
11 echo bin2hex(mb_convert_encoding(pack("H*", "1b24401b24402121"), "UTF-8", "ISO-2022-JP")), "\n";
12 echo bin2hex(mb_convert_encoding(pack("H*", "1b24421b24422121"), "UTF-8", "ISO-2022-JP")), "\n";
13 echo bin2hex(mb_convert_encoding(pack("H*", "1b28421b284261626364"), "UTF-8", "ISO-2022-JP")), "\n";
14 echo bin2hex(mb_convert_encoding(pack("H*", "1b284a1b284a61626364"), "UTF-8", "ISO-2022-JP")), "\n";
15 echo bin2hex(mb_convert_encoding(pack("H*", "1b24401b284261626364"), "UTF-8", "ISO-2022-JP")), "\n";
16 echo bin2hex(mb_convert_encoding(pack("H*", "1b24401b284a61626364"), "UTF-8", "ISO-2022-JP")), "\n";
17 echo bin2hex(mb_convert_encoding(pack("H*", "1b24421b284261626364"), "UTF-8", "ISO-2022-JP")), "\n";
18 echo bin2hex(mb_convert_encoding(pack("H*", "1b24421b284a61626364"), "UTF-8", "ISO-2022-JP")), "\n";
20 echo bin2hex(mb_convert_encoding(pack("H*", "1b2429430e0f61626364"), "UTF-8", "ISO-2022-KR")), "\n";
[all …]
H A Dmb_convert_encoding_array.phpt2 Test mb_convert_encoding() function : array functionality
6 function_exists('mb_convert_encoding') or die("skip mb_convert_encoding() is not available in this …
16 * Test basic functionality of mb_convert_encoding()
19 echo "*** Testing mb_convert_encoding() : array functionality ***\n";
43 var_dump(base64_encode_array(mb_convert_encoding($sjis_string, 'JIS', 'SJIS')));
45 var_dump(base64_encode_array(mb_convert_encoding($utf8_string, 'JIS', 'UTF-8')));
52 var_dump(base64_encode_array(mb_convert_encoding($jis_string, 'EUC-JP', 'JIS')));
59 var_dump(base64_encode_array(mb_convert_encoding($jis_string, 'SJIS', 'JIS')));
61 var_dump(base64_encode_array(mb_convert_encoding($utf8_string, 'SJIS', 'UTF-8')));
68 var_dump(base64_encode_array(mb_convert_encoding($jis_string, 'UTF-8', 'JIS')));
[all …]
H A Dmb_convert_encoding.phpt2 mb_convert_encoding()
47 $s = mb_convert_encoding($s, 'EUC-JP', $a);
51 $s = mb_convert_encoding($s, 'SJIS', $a);
55 $s = mb_convert_encoding($s, 'JIS', $a);
64 $s = mb_convert_encoding($s, 'EUC-JP', $a);
68 $s = mb_convert_encoding($s, 'SJIS', $a);
72 $s = mb_convert_encoding($s, 'JIS', $a);
95 $s = mb_convert_encoding(1234, 'EUC-JP');
98 $s = mb_convert_encoding('', 'EUC-JP');
102 $s = mb_convert_encoding($s, 'BAD');
[all …]
H A Dbug49528.phpt7 var_dump(bin2hex(mb_convert_encoding("\xff\xfe\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
8 var_dump(bin2hex(mb_convert_encoding("\xfe\xff\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
9 var_dump(bin2hex(mb_convert_encoding("\xff\xfe\xff\xfe\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
10 var_dump(bin2hex(mb_convert_encoding("\xff\xfe\xfe\xff\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
11 var_dump(bin2hex(mb_convert_encoding("\xfe\xff\xff\xfe\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
12 var_dump(bin2hex(mb_convert_encoding("\xfe\xff\xfe\xff\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
H A Dbug69086.phpt2 Request #69086 (enhancement for mb_convert_encoding)
8 var_dump("?" === mb_convert_encoding("\x80", "Shift_JIS", "EUC-JP"));
10 var_dump("\x00\x00\xff\xfd" === mb_convert_encoding("\x80", "UCS-4BE", "UTF-8"));
14 var_dump("\u{fffd}" === mb_convert_encoding("\x80", "UTF-8", "EUC-JP-2004"));
H A Dmb_substr_count.phpt24 var_dump(@mb_substr_count(mb_convert_encoding($a, $to_enc),
25 mb_convert_encoding($b, $to_enc), $to_enc));
28 var_dump(@mb_substr_count(mb_convert_encoding($a, $to_enc),
29 mb_convert_encoding($b, $to_enc), $to_enc));
H A Dmb_substitute_character_variation2.phpt21 var_dump(bin2hex(mb_convert_encoding($string_mb, "ISO-8859-1", "UTF-8")));
24 var_dump(bin2hex(mb_convert_encoding($string_mb, "ISO-8859-1", "UTF-8")));
26 var_dump(bin2hex(mb_convert_encoding($string_mb, "ISO-8859-1", "UTF-8")));
28 var_dump(bin2hex(mb_convert_encoding($string_mb, "ISO-8859-1", "UTF-8")));
H A Dmb_substitute_character.phpt15 var_dump(bin2hex(mb_convert_encoding("\xe2\x99\xa0\xe3\x81\x82", "CP932", "UTF-8")));
19 var_dump(bin2hex(mb_convert_encoding("\xe2\x99\xa0\xe3\x81\x82", "CP932", "UTF-8")));
23 var_dump(bin2hex(mb_convert_encoding("\xe2\x99\xa0\xe3\x81\x82", "CP932", "UTF-8")));
27 var_dump(bin2hex(mb_convert_encoding("\xe2\x99\xa0\xe3\x81\x82", "CP932", "UTF-8")));
H A Dmb_convert_encoding_leak.phpt2 mb_convert_encoding() shouldn't leak keys
8 mb_convert_encoding($array, 'UTF-8', 'UTF-8');
H A Doverload02.phpt23 $converted_str = mb_convert_encoding($str, 'Shift_JIS');
26 $c = mb_convert_encoding($c, 'Shift_JIS');
27 …$replaced = mb_convert_encoding(str_replace($c, '!!', $converted_str), mb_internal_encoding(), 'Sh…
H A Dbug25140.phpt2 Bug #25140 (mb_convert_encoding returns FALSE on an empty string)
7 var_dump( mb_convert_encoding( '', 'SJIS', 'EUC-JP' ) );
H A Dbug60306.phpt8 var_dump($s === mb_convert_encoding(mb_convert_encoding($s, "cp936", "utf8"), "utf8", "cp936"));
H A Dbug65045.phpt2 Bug #65045: mb_convert_encoding breaks well-formed character
21 $expected === mb_convert_encoding($str, 'UTF-8', 'UTF-8'),
22 $expected2 === mb_convert_encoding($str2, 'UTF-8', 'UTF-8')
H A Dbug46843.phpt7 var_dump(bin2hex(mb_convert_encoding("\x80", 'UCS-2BE', 'CP936')));
8 var_dump(bin2hex(mb_convert_encoding("\x20\xac", 'CP936', 'UCS-2BE')));
H A Dmb_ereg.phpt18 $pat = mb_convert_encoding( $pat, $test_enc, $in_enc );
19 $str = mb_convert_encoding( $str, $test_enc, $in_enc );
20 …printf( "(%d)%s\n", mb_ereg( $pat, $str, $reg ), ( is_array( $reg )? bin2hex(mb_convert_encoding( …
H A Dbug62545.phpt10 bin2hex(mb_convert_encoding("\x98", 'UTF-8', 'Windows-1251')),
11 bin2hex(mb_convert_encoding("\x81\x8d\x8f\x90\x9d", 'UTF-8', 'Windows-1252'))
H A Dmb_strstr.phpt10 return mb_convert_encoding($utf8str, "EUC-JP", "UTF-8");
14 return mb_convert_encoding($eucjpstr, "UTF-8", "EUC-JP");
H A Dmb_ereg_search_xxx.phpt18 $str = mb_convert_encoding( $str, $test_enc, $in_enc );
19 $look_for = mb_convert_encoding( $look_for, $test_enc, $in_enc );
24 …printf( "(%s) (%d) %s\n", $test_enc, mb_ereg_search_getpos(), mb_convert_encoding( ( is_array( $re…
H A Dbug54494.phpt19 $string = mb_convert_encoding($stringOr, $mode);
35 $string = mb_convert_encoding($stringOr, $mode);
H A Dmb_strcut_missing_boundary_check.phpt6 function_exists('mb_convert_encoding') or die("skip mb_convert_encoding() is not available in this …

Completed in 34 milliseconds

12