From 6b8e967a7ce62a2144d0aa88e0ac3415552e5daf Mon Sep 17 00:00:00 2001 From: Hex Date: Wed, 26 Nov 2025 17:40:40 +0800 Subject: [PATCH 1/4] Fix typo in getVar() method documentation --- user_guide_src/source/incoming/incomingrequest.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/user_guide_src/source/incoming/incomingrequest.rst b/user_guide_src/source/incoming/incomingrequest.rst index 0b6f3daab39e..2f73dff4bdf2 100644 --- a/user_guide_src/source/incoming/incomingrequest.rst +++ b/user_guide_src/source/incoming/incomingrequest.rst @@ -161,7 +161,7 @@ getVar() in new projects. Even if you are already using it, we recommend that you use another, more appropriate method. -The ``getVar()`` method will pull from ``$_REQUEST``, so will return any data from ``$_GET``, ``$POST``, or ``$_COOKIE`` (depending on php.ini `request-order `_). +The ``getVar()`` method will pull from ``$_REQUEST``, so will return any data from ``$_GET``, ``$_POST``, or ``$_COOKIE`` (depending on php.ini `request-order `_). .. warning:: If you want to validate POST data only, don't use ``getVar()``. Newer values override older values. POST values may be overridden by the From 4a241bf013efc816e09daf12cd95d0e2efe5f9b0 Mon Sep 17 00:00:00 2001 From: Hex Date: Thu, 27 Nov 2025 10:38:12 +0800 Subject: [PATCH 2/4] Fix links to PHP filter documentation --- .../source/incoming/incomingrequest.rst | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/user_guide_src/source/incoming/incomingrequest.rst b/user_guide_src/source/incoming/incomingrequest.rst index 2f73dff4bdf2..55a6b1136075 100644 --- a/user_guide_src/source/incoming/incomingrequest.rst +++ b/user_guide_src/source/incoming/incomingrequest.rst @@ -229,7 +229,7 @@ Filtering Input Data To maintain security of your application, you will want to filter all input as you access it. You can pass the type of filter to use as the second parameter of any of these methods. The native ``filter_var()`` function is used for the filtering. Head over to the PHP manual for a list of `valid -filter types `_. +filter types `_. Filtering a POST variable would look like this: @@ -366,7 +366,7 @@ The methods provided by the parent classes that are available are: :param string $index: The name of the variable/key to look for. :param int $filter: The type of filter to apply. A list of filters can be found in - `Types of filters `__. + `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in `Filter flags `__. :returns: ``$_REQUEST`` if no parameters supplied, otherwise the REQUEST value if found, or null if not @@ -382,7 +382,7 @@ The methods provided by the parent classes that are available are: :param string $index: The name of the variable/key to look for. :param int $filter: The type of filter to apply. A list of filters can be found in - `Types of filters `__. + `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in `Filter flags `__. :returns: ``$_GET`` if no parameters supplied, otherwise the GET value if found, or null if not @@ -421,7 +421,7 @@ The methods provided by the parent classes that are available are: :param string $index: The name of the variable/key to look for. :param int $filter: The type of filter to apply. A list of filters can be - found `here `__. + found `here `__. :param int $flags: Flags to apply. A list of flags can be found `here `__. :returns: ``$_POST`` if no parameters supplied, otherwise the POST value if found, or null if not @@ -433,7 +433,7 @@ The methods provided by the parent classes that are available are: :param string $index: The name of the variable/key to look for. :param int $filter: The type of filter to apply. A list of filters can be found in - `Types of filters `__. + `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in `Filter flags `__. :returns: ``$_POST`` and ``$_GET`` combined if no parameters specified (prefer POST value on conflict), @@ -453,7 +453,7 @@ The methods provided by the parent classes that are available are: :param string $index: The name of the variable/key to look for. :param int $filter: The type of filter to apply. A list of filters can be found in - `Types of filters `__. + `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in `Filter flags `__. :returns: ``$_GET`` and ``$_POST`` combined if no parameters specified (prefer GET value on conflict), @@ -473,7 +473,7 @@ The methods provided by the parent classes that are available are: :param array|string|null $index: COOKIE name :param int $filter: The type of filter to apply. A list of filters can be found in - `Types of filters `__. + `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in `Filter flags `__. :returns: ``$_COOKIE`` if no parameters supplied, otherwise the COOKIE value if found or null if not @@ -495,7 +495,7 @@ The methods provided by the parent classes that are available are: :param array|string|null $index: Value name :param int $filter: The type of filter to apply. A list of filters can be found in - `Types of filters `__. + `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in `Filter flags `__. :returns: ``$_SERVER`` item value if found, null if not From 78dfcf5d5624709c6c979f8418d8c62a94a24e2e Mon Sep 17 00:00:00 2001 From: Hex Date: Thu, 27 Nov 2025 12:29:50 +0800 Subject: [PATCH 3/4] Update filter flags links in incomingrequest.rst --- user_guide_src/source/incoming/incomingrequest.rst | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/user_guide_src/source/incoming/incomingrequest.rst b/user_guide_src/source/incoming/incomingrequest.rst index 55a6b1136075..e22c4ce37773 100644 --- a/user_guide_src/source/incoming/incomingrequest.rst +++ b/user_guide_src/source/incoming/incomingrequest.rst @@ -368,7 +368,7 @@ The methods provided by the parent classes that are available are: :param int $filter: The type of filter to apply. A list of filters can be found in `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in - `Filter flags `__. + `Filter flags `__. :returns: ``$_REQUEST`` if no parameters supplied, otherwise the REQUEST value if found, or null if not :rtype: array|bool|float|int|object|string|null @@ -384,7 +384,7 @@ The methods provided by the parent classes that are available are: :param int $filter: The type of filter to apply. A list of filters can be found in `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in - `Filter flags `__. + `Filter flags `__. :returns: ``$_GET`` if no parameters supplied, otherwise the GET value if found, or null if not :rtype: array|bool|float|int|object|string|null @@ -423,7 +423,7 @@ The methods provided by the parent classes that are available are: :param int $filter: The type of filter to apply. A list of filters can be found `here `__. :param int $flags: Flags to apply. A list of flags can be found - `here `__. + `here `__. :returns: ``$_POST`` if no parameters supplied, otherwise the POST value if found, or null if not :rtype: array|bool|float|int|object|string|null @@ -435,7 +435,7 @@ The methods provided by the parent classes that are available are: :param int $filter: The type of filter to apply. A list of filters can be found in `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in - `Filter flags `__. + `Filter flags `__. :returns: ``$_POST`` and ``$_GET`` combined if no parameters specified (prefer POST value on conflict), otherwise looks for POST value, if nothing found looks for GET value, if no value found returns null :rtype: array|bool|float|int|object|string|null @@ -455,7 +455,7 @@ The methods provided by the parent classes that are available are: :param int $filter: The type of filter to apply. A list of filters can be found in `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in - `Filter flags `__. + `Filter flags `__. :returns: ``$_GET`` and ``$_POST`` combined if no parameters specified (prefer GET value on conflict), otherwise looks for GET value, if nothing found looks for POST value, if no value found returns null :rtype: array|bool|float|int|object|string|null @@ -475,7 +475,7 @@ The methods provided by the parent classes that are available are: :param int $filter: The type of filter to apply. A list of filters can be found in `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in - `Filter flags `__. + `Filter flags `__. :returns: ``$_COOKIE`` if no parameters supplied, otherwise the COOKIE value if found or null if not :rtype: array|bool|float|int|object|string|null @@ -497,7 +497,7 @@ The methods provided by the parent classes that are available are: :param int $filter: The type of filter to apply. A list of filters can be found in `Types of filters `__. :param int $flags: Flags to apply. A list of flags can be found in - `Filter flags `__. + `Filter flags `__. :returns: ``$_SERVER`` item value if found, null if not :rtype: array|bool|float|int|object|string|null From 4e3a6ff478fa17029241878a96e4f570681d36cc Mon Sep 17 00:00:00 2001 From: Hex Date: Thu, 27 Nov 2025 15:22:46 +0800 Subject: [PATCH 4/4] Update filter documentation links in request.rst --- user_guide_src/source/incoming/request.rst | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/user_guide_src/source/incoming/request.rst b/user_guide_src/source/incoming/request.rst index 9e7bf899917a..64c427f1b0d3 100644 --- a/user_guide_src/source/incoming/request.rst +++ b/user_guide_src/source/incoming/request.rst @@ -86,8 +86,8 @@ Class Reference .. php:method:: getServer([$index = null[, $filter = null[, $flags = null]]]) :param mixed $index: Value name - :param int $filter: The type of filter to apply. A list of filters can be found in `PHP manual `__. - :param int|array $flags: Flags to apply. A list of flags can be found in `PHP manual `__. + :param int $filter: The type of filter to apply. A list of filters can be found in `PHP manual `__. + :param int|array $flags: Flags to apply. A list of flags can be found in `PHP manual `__. :returns: ``$_SERVER`` item value if found, null if not :rtype: mixed @@ -107,8 +107,8 @@ Class Reference :php:func:`env()` instead. :param mixed $index: Value name - :param int $filter: The type of filter to apply. A list of filters can be found in `PHP manual `__. - :param int|array $flags: Flags to apply. A list of flags can be found in `PHP manual `__. + :param int $filter: The type of filter to apply. A list of filters can be found in `PHP manual `__. + :param int|array $flags: Flags to apply. A list of flags can be found in `PHP manual `__. :returns: ``$_ENV`` item value if found, null if not :rtype: mixed @@ -135,8 +135,8 @@ Class Reference :param string $method: Input filter constant :param mixed $index: Value name - :param int $filter: The type of filter to apply. A list of filters can be found in `PHP manual `__. - :param int|array $flags: Flags to apply. A list of flags can be found in `PHP manual `__. + :param int $filter: The type of filter to apply. A list of filters can be found in `PHP manual `__. + :param int|array $flags: Flags to apply. A list of flags can be found in `PHP manual `__. :rtype: mixed Fetches one or more items from a global, like cookies, get, post, etc.