PluginProbe ʕ •ᴥ•ʔ
Matomo Analytics – Powerful, Privacy-First Insights for WordPress / 5.12.1
Matomo Analytics – Powerful, Privacy-First Insights for WordPress v5.12.1
5.12.1 5.12.0 5.11.1 5.11.0 5.10.2 5.10.1 trunk 1.0.2 1.0.3 1.0.4 1.0.5 1.0.6 1.1.0 1.1.1 1.1.2 1.1.3 1.2.0 1.3.0 1.3.1 1.3.2 4.0.0 4.0.1 4.0.2 4.0.3 4.0.4 4.1.0 4.1.1 4.1.2 4.1.3 4.10.0 4.11.0 4.12.0 4.13.0 4.13.2 4.13.3 4.13.4 4.13.5 4.14.0 4.14.1 4.14.2 4.15.0 4.15.1 4.15.2 4.15.3 4.2.0 4.3.0 4.3.1 4.4.1 4.4.2 4.5.0 4.6.0 5.0.1 5.0.2 5.0.3 5.0.4 5.0.5 5.0.6 5.0.7 5.0.8 5.1.0 5.1.1 5.1.2 5.1.3 5.1.4 5.1.5 5.1.6 5.1.7 5.10.0 5.2.0 5.2.1 5.2.2 5.3.0 5.3.1 5.3.2 5.3.3 5.6.0 5.6.1 5.7.0 5.7.1 5.8.0 5.8.1 5.8.2
matomo / app / vendor / symfony / polyfill-iconv / bootstrap80.php
matomo / app / vendor / symfony / polyfill-iconv Last commit date
Resources 2 years ago Iconv.php 3 months ago LICENSE 2 years ago README.md 4 years ago bootstrap.php 8 months ago bootstrap80.php 8 months ago
bootstrap80.php
128 lines
1 <?php
2
3 namespace {
4 /*
5 * This file is part of the Symfony package.
6 *
7 * (c) Fabien Potencier <fabien@symfony.com>
8 *
9 * For the full copyright and license information, please view the LICENSE
10 * file that was distributed with this source code.
11 */
12 use Symfony\Polyfill\Iconv as p;
13 if (!\defined('ICONV_IMPL')) {
14 \define('ICONV_IMPL', 'Symfony');
15 }
16 if (!\defined('ICONV_VERSION')) {
17 \define('ICONV_VERSION', '1.0');
18 }
19 if (!\defined('ICONV_MIME_DECODE_STRICT')) {
20 \define('ICONV_MIME_DECODE_STRICT', 1);
21 }
22 if (!\defined('ICONV_MIME_DECODE_CONTINUE_ON_ERROR')) {
23 \define('ICONV_MIME_DECODE_CONTINUE_ON_ERROR', 2);
24 }
25 if (!\function_exists('iconv')) {
26 function iconv(?string $from_encoding, ?string $to_encoding, ?string $string) : string|false
27 {
28 return p\Iconv::iconv((string) $from_encoding, (string) $to_encoding, (string) $string);
29 }
30 }
31 if (!\function_exists('iconv_get_encoding')) {
32 function iconv_get_encoding(?string $type = 'all') : array|string|false
33 {
34 return p\Iconv::iconv_get_encoding((string) $type);
35 }
36 }
37 if (!\function_exists('iconv_set_encoding')) {
38 function iconv_set_encoding(?string $type, ?string $encoding) : bool
39 {
40 return p\Iconv::iconv_set_encoding((string) $type, (string) $encoding);
41 }
42 }
43 if (!\function_exists('iconv_mime_encode')) {
44 function iconv_mime_encode(?string $field_name, ?string $field_value, ?array $options = []) : string|false
45 {
46 return p\Iconv::iconv_mime_encode((string) $field_name, (string) $field_value, (array) $options);
47 }
48 }
49 if (!\function_exists('iconv_mime_decode_headers')) {
50 function iconv_mime_decode_headers(?string $headers, ?int $mode = 0, ?string $encoding = null) : array|false
51 {
52 return p\Iconv::iconv_mime_decode_headers((string) $headers, (int) $mode, $encoding);
53 }
54 }
55 if (\extension_loaded('mbstring')) {
56 if (!\function_exists('iconv_strlen')) {
57 function iconv_strlen(?string $string, ?string $encoding = null) : int|false
58 {
59 null === $encoding && ($encoding = p\Iconv::$internalEncoding);
60 return \mb_strlen((string) $string, $encoding);
61 }
62 }
63 if (!\function_exists('iconv_strpos')) {
64 function iconv_strpos(?string $haystack, ?string $needle, ?int $offset = 0, ?string $encoding = null) : int|false
65 {
66 null === $encoding && ($encoding = p\Iconv::$internalEncoding);
67 return \mb_strpos((string) $haystack, (string) $needle, (int) $offset, $encoding);
68 }
69 }
70 if (!\function_exists('iconv_strrpos')) {
71 function iconv_strrpos(?string $haystack, ?string $needle, ?string $encoding = null) : int|false
72 {
73 null === $encoding && ($encoding = p\Iconv::$internalEncoding);
74 return \mb_strrpos((string) $haystack, (string) $needle, 0, $encoding);
75 }
76 }
77 if (!\function_exists('iconv_substr')) {
78 function iconv_substr(?string $string, ?int $offset, ?int $length = null, ?string $encoding = null) : string|false
79 {
80 null === $encoding && ($encoding = p\Iconv::$internalEncoding);
81 return \mb_substr((string) $string, (int) $offset, $length, $encoding);
82 }
83 }
84 if (!\function_exists('iconv_mime_decode')) {
85 function iconv_mime_decode($string, $mode = 0, $encoding = null)
86 {
87 $currentMbEncoding = \mb_internal_encoding();
88 null === $encoding && ($encoding = p\Iconv::$internalEncoding);
89 \mb_internal_encoding($encoding);
90 $decoded = \mb_decode_mimeheader($string);
91 \mb_internal_encoding($currentMbEncoding);
92 return $decoded;
93 }
94 }
95 } else {
96 if (!\function_exists('iconv_strlen')) {
97 function iconv_strlen(?string $string, ?string $encoding = null) : int|false
98 {
99 return p\Iconv::iconv_strlen((string) $string, $encoding);
100 }
101 }
102 if (!\function_exists('iconv_strpos')) {
103 function iconv_strpos(?string $haystack, ?string $needle, ?int $offset = 0, ?string $encoding = null) : int|false
104 {
105 return p\Iconv::iconv_strpos((string) $haystack, (string) $needle, (int) $offset, $encoding);
106 }
107 }
108 if (!\function_exists('iconv_strrpos')) {
109 function iconv_strrpos(?string $haystack, ?string $needle, ?string $encoding = null) : int|false
110 {
111 return p\Iconv::iconv_strrpos((string) $haystack, (string) $needle, $encoding);
112 }
113 }
114 if (!\function_exists('iconv_substr')) {
115 function iconv_substr(?string $string, ?int $offset, ?int $length = null, ?string $encoding = null) : string|false
116 {
117 return p\Iconv::iconv_substr((string) $string, (string) $offset, $length, $encoding);
118 }
119 }
120 if (!\function_exists('iconv_mime_decode')) {
121 function iconv_mime_decode(?string $string, ?int $mode = 0, ?string $encoding = null) : string|false
122 {
123 return p\Iconv::iconv_mime_decode((string) $string, (int) $mode, $encoding);
124 }
125 }
126 }
127 }
128