reference/mbstring/functions/mb-ereg-replace.xml
1187e24a8417e8a0fa4a80a026c565cd3f3f1208
...
...
@@ -9,11 +9,11 @@
9
9
<refsect1 role="description">
10
10
&reftitle.description;
11
11
<methodsynopsis>
12
-
<type>string</type><methodname>mb_ereg_replace</methodname>
12
+
<type class="union"><type>string</type><type>false</type><type>null</type></type><methodname>mb_ereg_replace</methodname>
13
13
<methodparam><type>string</type><parameter>pattern</parameter></methodparam>
14
14
<methodparam><type>string</type><parameter>replacement</parameter></methodparam>
15
15
<methodparam><type>string</type><parameter>string</parameter></methodparam>
16
-
<methodparam choice="opt"><type>string</type><parameter>option</parameter><initializer>"msr"</initializer></methodparam>
16
+
<methodparam choice="opt"><type class="union"><type>string</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
17
17
</methodsynopsis>
18
18
<simpara>
19
19
Scans <parameter>string</parameter> for matches to
...
...
@@ -54,19 +54,10 @@
54
54
</listitem>
55
55
</varlistentry>
56
56
<varlistentry>
57
-
<term><parameter>option</parameter></term>
57
+
<term><parameter>options</parameter></term>
58
58
<listitem>
59
59
<simpara>
60
-
Matching condition can be set by <parameter>option</parameter>
61
-
parameter. If <literal>i</literal> is specified for this
62
-
parameter, the case will be ignored. If <literal>x</literal> is
63
-
specified, white space will be ignored. If <literal>m</literal>
64
-
is specified, match will be executed in multiline mode and line
65
-
break will be included in '.'. If <literal>p</literal> is
66
-
specified, match will be executed in POSIX mode, line break
67
-
will be considered as normal character. If <literal>e</literal>
68
-
is specified, <parameter>replacement</parameter> string will be
69
-
evaluated as PHP expression.
60
+
The search option. See <function>mb_regex_set_options</function> for explanation.
70
61
</simpara>
71
62
</listitem>
72
63
</varlistentry>
...
...
@@ -78,6 +69,8 @@
78
69
&reftitle.returnvalues;
79
70
<para>
80
71
The resultant <type>string</type> on success, or &false; on error.
72
+
If <parameter>string</parameter> is not valid for the current encoding, &null;
73
+
is returned.
81
74
</para>
82
75
</refsect1>
83
76

...
...
@@ -94,6 +87,19 @@
94
87
</thead>
95
88
<tbody>
96
89
<row>
90
+
<entry>8.0.0</entry>
91
+
<entry>
92
+
<parameter>options</parameter> is nullable now.
93
+
</entry>
94
+
</row>
95
+
<row>
96
+
<entry>7.1.0</entry>
97
+
<entry>
98
+
The function checks whether <parameter>string</parameter> is valid for the
99
+
current encoding.
100
+
</entry>
101
+
</row>
102
+
<row>
97
103
<entry>7.1.0</entry>
98
104
<entry>
99
105
The <literal>e</literal> modifier has been deprecated.
...
...
@@ -123,7 +129,6 @@
123
129
</refsect1>
124
130

125
131
</refentry>
126
-

127
132
<!-- Keep this comment at the end of the file
128
133
Local variables:
129
134
mode: sgml
130
135