reference/mbstring/functions/mb-substitute-character.xml
92f1b8b177eb5730382abf9f27bae868f1bb636f
...
...
@@ -9,14 +9,14 @@
9
9
<refsect1 role="description">
10
10
&reftitle.description;
11
11
<methodsynopsis>
12
-
<type>mixed</type><methodname>mb_substitute_character</methodname>
13
-
<methodparam choice="opt"><type>mixed</type><parameter>substchar</parameter><initializer>mb_substitute_character()</initializer></methodparam>
12
+
<type class="union"><type>string</type><type>int</type><type>bool</type></type><methodname>mb_substitute_character</methodname>
13
+
<methodparam choice="opt"><type class="union"><type>string</type><type>int</type><type>null</type></type><parameter>substitute_character</parameter><initializer>&null;</initializer></methodparam>
14
14
</methodsynopsis>
15
15
<para>
16
16
Specifies a substitution character when input character encoding is invalid
17
17
or character code does not exist in output character
18
-
encoding. Invalid characters may be substituted &null; (no output),
19
-
<type>string</type> or <type>integer</type> value (Unicode character code value).
18
+
encoding. Invalid characters may be substituted <literal>"none"</literal> (no output),
19
+
<type>string</type> or <type>int</type> value (Unicode character code value).
20
20
</para>
21
21
<para>
22
22
This setting affects <function>mb_convert_encoding</function>,
...
...
@@ -31,10 +31,10 @@
31
31
<para>
32
32
<variablelist>
33
33
<varlistentry>
34
-
<term><parameter>substchar</parameter></term>
34
+
<term><parameter>substitute_character</parameter></term>
35
35
<listitem>
36
36
<para>
37
-
Specify the Unicode value as an <type>integer</type>,
37
+
Specify the Unicode value as an <type>int</type>,
38
38
or as one of the following <type>string</type>s:
39
39
<itemizedlist>
40
40
<listitem>
...
...
@@ -65,13 +65,37 @@
65
65
<refsect1 role="returnvalues">
66
66
&reftitle.returnvalues;
67
67
<para>
68
-
If <parameter>substchar</parameter> is set, it returns &true; for success,
68
+
If <parameter>substitute_character</parameter> is set, it returns &true; for success,
69
69
otherwise returns &false;.
70
-
If <parameter>substchar</parameter> is not set, it returns the current
70
+
If <parameter>substitute_character</parameter> is not set, it returns the current
71
71
setting.
72
72
</para>
73
73
</refsect1>
74
74

75
+
<refsect1 role="changelog">
76
+
&reftitle.changelog;
77
+
<informaltable>
78
+
<tgroup cols="2">
79
+
<thead>
80
+
<row>
81
+
<entry>&Version;</entry>
82
+
<entry>&Description;</entry>
83
+
</row>
84
+
</thead>
85
+
<tbody>
86
+
<row>
87
+
<entry>8.0.0</entry>
88
+
<entry>
89
+
Passing an empty string to <parameter>substitute_character</parameter>
90
+
is no longer supported; <literal>"none"</literal> should be passed instead.
91
+
</entry>
92
+
</row>
93
+
&mbstring.changelog.encoding-nullable;
94
+
</tbody>
95
+
</tgroup>
96
+
</informaltable>
97
+
</refsect1>
98
+

75
99
<refsect1 role="examples">
76
100
&reftitle.examples;
77
101
<para>
...
...
@@ -96,7 +120,6 @@ echo mb_substitute_character();
96
120
</refsect1>
97
121

98
122
</refentry>
99
-

100
123
<!-- Keep this comment at the end of the file
101
124
Local variables:
102
125
mode: sgml
103
126