Note: FILTER_NULL_ON_FAILURE, FILTER_REQUIRE_SCALAR, FILTER_REQUIRE_ARRAY and FILTER_FORCE_ARRAY dont have prefix "FILTER_FLAG_" but they are FLAGS!
The constants below are defined by this extension, and will only be available when the extension has either been compiled into PHP or dynamically loaded at runtime.
INPUT_POST
(int)
INPUT_GET
(int)
INPUT_ENV
(int)
INPUT_SERVER
(int)
INPUT_SESSION
(int)
INPUT_REQUEST
(int)
FILTER_FLAG_NONE
(int)
FILTER_REQUIRE_SCALAR
(int)
FILTER_REQUIRE_ARRAY
(int)
FILTER_FORCE_ARRAY
(int)
FILTER_NULL_ON_FAILURE
(int)
FILTER_VALIDATE_INT
(int)
FILTER_VALIDATE_BOOL
(int)
FILTER_VALIDATE_BOOLEAN
.
FILTER_VALIDATE_BOOLEAN
(int)
FILTER_VALIDATE_FLOAT
(int)
FILTER_VALIDATE_REGEXP
(int)
FILTER_VALIDATE_URL
(int)
FILTER_VALIDATE_DOMAIN
(int)
FILTER_VALIDATE_EMAIL
(int)
FILTER_VALIDATE_IP
(int)
FILTER_VALIDATE_MAC
(int)
FILTER_DEFAULT
(int)
FILTER_UNSAFE_RAW
.
FILTER_UNSAFE_RAW
(int)
FILTER_SANITIZE_STRING
(int)
FILTER_SANITIZE_STRIPPED
(int)
FILTER_SANITIZE_ENCODED
(int)
FILTER_SANITIZE_SPECIAL_CHARS
(int)
FILTER_SANITIZE_EMAIL
(int)
FILTER_SANITIZE_URL
(int)
FILTER_SANITIZE_NUMBER_INT
(int)
FILTER_SANITIZE_NUMBER_FLOAT
(int)
FILTER_SANITIZE_MAGIC_QUOTES
(int)
FILTER_SANITIZE_ADD_SLASHES
instead.)
FILTER_SANITIZE_ADD_SLASHES
(int)
FILTER_CALLBACK
(int)
FILTER_FLAG_ALLOW_OCTAL
(int)
0[0-7]+
) in "int" filter.
FILTER_FLAG_ALLOW_HEX
(int)
0x[0-9a-fA-F]+
) in "int" filter.
FILTER_FLAG_STRIP_LOW
(int)
FILTER_FLAG_STRIP_HIGH
(int)
FILTER_FLAG_STRIP_BACKTICK
(int)
FILTER_FLAG_ENCODE_LOW
(int)
FILTER_FLAG_ENCODE_HIGH
(int)
FILTER_FLAG_ENCODE_AMP
(int)
&
.
FILTER_FLAG_NO_ENCODE_QUOTES
(int)
'
and "
.
FILTER_FLAG_EMPTY_STRING_NULL
(int)
FILTER_FLAG_ALLOW_FRACTION
(int)
FILTER_FLAG_ALLOW_THOUSAND
(int)
,
) in "number_float" filter.
FILTER_FLAG_ALLOW_SCIENTIFIC
(int)
e
, E
) in
"number_float" filter.
FILTER_FLAG_PATH_REQUIRED
(int)
FILTER_FLAG_QUERY_REQUIRED
(int)
FILTER_FLAG_SCHEME_REQUIRED
(int)
FILTER_FLAG_HOST_REQUIRED
(int)
FILTER_FLAG_HOSTNAME
(int)
FILTER_FLAG_IPV4
(int)
FILTER_FLAG_IPV6
(int)
FILTER_FLAG_NO_RES_RANGE
(int)
FILTER_FLAG_NO_PRIV_RANGE
(int)
FILTER_FLAG_EMAIL_UNICODE
(int)
Note: FILTER_NULL_ON_FAILURE, FILTER_REQUIRE_SCALAR, FILTER_REQUIRE_ARRAY and FILTER_FORCE_ARRAY dont have prefix "FILTER_FLAG_" but they are FLAGS!
INPUT_REQUEST was implemented in PHP < 8 (it was equal to 99) but it was removed in PHP 8.0
While INPUT_SESSION,FILTER_SANITIZE_MAGIC_QUOTES,FILTER_FLAG_SCHEME_REQUIRED,FILTER_FLAG_HOST_REQUIRED and a few others were removed in PHP 8.0.