[doc-en] master: trim: document form feed in the default characters (PHP 8.6) (#6031)
| From: | Alejandro Borrego via GitHub | Date: | Mon, 02 Nov 2026 14:07:32 +0000 |
| Subject: | [doc-en] master: trim: document form feed in the default characters (PHP 8.6) (#6031) | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-23907@lists.php.net to get a copy of this message | ||
Author: Alejandro Borrego (abp002)
Committer: GitHub (web-flow)
Pusher: lacatoire
Date: 2026-11-02T15:07:28+01:00
Commit: https://github.com/php/doc-en/commit/096d06958c721fb8408a3cc52375d7034b409d32
Raw diff: https://github.com/php/doc-en/commit/096d06958c721fb8408a3cc52375d7034b409d32.diff
trim: document form feed in the default characters (PHP 8.6) (#6031)
Co-authored-by: Alejandro Borrego <210245044+abp002@users.noreply.github.com>
Changed paths:
M language-snippets.ent
M reference/strings/functions/ltrim.xml
M reference/strings/functions/rtrim.xml
M reference/strings/functions/trim.xml
Diff:
diff --git a/language-snippets.ent b/language-snippets.ent
index c287327f71da..7cf8ff649fa6 100644
--- a/language-snippets.ent
+++ b/language-snippets.ent
@@ -3596,6 +3596,12 @@ local: {
character <literal>0x0B</literal>, a vertical tab.
</simpara>
</listitem>
+ <listitem>
+ <simpara>
+ <literal>"\f"</literal>: <acronym>ASCII</acronym>
<acronym>FF</acronym>
+ character <literal>0x0C</literal>, a form feed (as of PHP 8.6.0).
+ </simpara>
+ </listitem>
</itemizedlist>
'>
diff --git a/reference/strings/functions/ltrim.xml b/reference/strings/functions/ltrim.xml
index f5b3847386e0..1883218e63a1 100644
--- a/reference/strings/functions/ltrim.xml
+++ b/reference/strings/functions/ltrim.xml
@@ -11,7 +11,7 @@
<methodsynopsis>
<type>string</type><methodname>ltrim</methodname>
<methodparam><type>string</type><parameter>string</parameter></methodparam>
- <methodparam
choice="opt"><type>string</type><parameter>characters</parameter><initializer>"
\n\r\t\v\x00"</initializer></methodparam>
+ <methodparam
choice="opt"><type>string</type><parameter>characters</parameter><initializer>"
\f\n\r\t\v\x00"</initializer></methodparam>
</methodsynopsis>
<simpara>
Strip whitespace (or other characters) from the beginning of a string.
@@ -51,6 +51,29 @@
</simpara>
</refsect1>
+ <refsect1 role="changelog">
+ &reftitle.changelog;
+ <informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>&Version;</entry>
+ <entry>&Description;</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry>8.6.0</entry>
+ <entry>
+ The form feed character (<literal>"\f"</literal>) was added to the
+ default value of <parameter>characters</parameter>.
+ </entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </informaltable>
+ </refsect1>
+
<refsect1 role="examples">
&reftitle.examples;
<para>
diff --git a/reference/strings/functions/rtrim.xml b/reference/strings/functions/rtrim.xml
index df23e95bd358..e9a7f643e629 100644
--- a/reference/strings/functions/rtrim.xml
+++ b/reference/strings/functions/rtrim.xml
@@ -11,7 +11,7 @@
<methodsynopsis>
<type>string</type><methodname>rtrim</methodname>
<methodparam><type>string</type><parameter>string</parameter></methodparam>
- <methodparam
choice="opt"><type>string</type><parameter>characters</parameter><initializer>"
\n\r\t\v\x00"</initializer></methodparam>
+ <methodparam
choice="opt"><type>string</type><parameter>characters</parameter><initializer>"
\f\n\r\t\v\x00"</initializer></methodparam>
</methodsynopsis>
<simpara>
This function returns a string with whitespace (or other characters) stripped from the
@@ -51,6 +51,29 @@
</simpara>
</refsect1>
+ <refsect1 role="changelog">
+ &reftitle.changelog;
+ <informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>&Version;</entry>
+ <entry>&Description;</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry>8.6.0</entry>
+ <entry>
+ The form feed character (<literal>"\f"</literal>) was added to the
+ default value of <parameter>characters</parameter>.
+ </entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </informaltable>
+ </refsect1>
+
<refsect1 role="examples">
&reftitle.examples;
<para>
diff --git a/reference/strings/functions/trim.xml b/reference/strings/functions/trim.xml
index 6c1f0c1354c6..a50482e9e20e 100644
--- a/reference/strings/functions/trim.xml
+++ b/reference/strings/functions/trim.xml
@@ -12,7 +12,7 @@
<methodsynopsis>
<type>string</type><methodname>trim</methodname>
<methodparam><type>string</type><parameter>string</parameter></methodparam>
- <methodparam
choice="opt"><type>string</type><parameter>characters</parameter><initializer>"
\n\r\t\v\x00"</initializer></methodparam>
+ <methodparam
choice="opt"><type>string</type><parameter>characters</parameter><initializer>"
\f\n\r\t\v\x00"</initializer></methodparam>
</methodsynopsis>
<simpara>
This function returns a string with whitespace stripped from the
@@ -50,6 +50,29 @@
</simpara>
</refsect1>
+ <refsect1 role="changelog">
+ &reftitle.changelog;
+ <informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>&Version;</entry>
+ <entry>&Description;</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry>8.6.0</entry>
+ <entry>
+ The form feed character (<literal>"\f"</literal>) was added to the
+ default value of <parameter>characters</parameter>.
+ </entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </informaltable>
+ </refsect1>
+
<refsect1 role="examples">
&reftitle.examples;
<para>