reference/strings/functions/substr.xml
62126c55f1c6ed444043e7272c4f9e233818a44b
...
...
@@ -218,27 +218,25 @@ echo "7) ".var_export(substr(1.2e3, 0, 4), true).PHP_EOL;
218
218
If an invalid character range is requested, <function>substr</function> returns
219
219
an empty string as of PHP 8.0.0; previously, &false; was returned instead.
220
220
</para>
221
-
<example>
222
-
<programlisting role="php">
221
+
<programlisting role="php">
223
222
<![CDATA[
224
223
<?php
225
224
var_dump(substr('a', 2));
226
225
?>
227
226
]]>
228
-
</programlisting>
229
-
&example.outputs.8;
230
-
<screen>
227
+
</programlisting>
228
+
&example.outputs.8;
229
+
<screen>
231
230
<![CDATA[
232
231
string(0) ""
233
232
]]>
234
-
</screen>
235
-
&example.outputs.7;
236
-
<screen>
233
+
</screen>
234
+
&example.outputs.7;
235
+
<screen>
237
236
<![CDATA[
238
237
bool(false)
239
238
]]>
240
-
</screen>
241
-
</example>
239
+
</screen>
242
240
</example>
243
241
</para>
244
242
</refsect1>
245
243