|
@@ 965-974 (lines=10) @@
|
| 962 |
|
* returns <b>FALSE</b> if the variable is not set and <b>NULL</b> if the filter fails. |
| 963 |
|
* @since 5.2.0 |
| 964 |
|
*/ |
| 965 |
|
public static function filter_input(int $type, string $variable_name, int $filter = FILTER_DEFAULT, $options = null) |
| 966 |
|
{ |
| 967 |
|
if (4 > \func_num_args()) { |
| 968 |
|
$var = \filter_input($type, $variable_name, $filter); |
| 969 |
|
} else { |
| 970 |
|
$var = \filter_input($type, $variable_name, $filter, $options); |
| 971 |
|
} |
| 972 |
|
|
| 973 |
|
return self::filter($var); |
| 974 |
|
} |
| 975 |
|
|
| 976 |
|
/** |
| 977 |
|
* "filter_input_array()"-wrapper with normalizes to UTF-8 NFC, converting from WINDOWS-1252 when needed. |
|
@@ 1083-1092 (lines=10) @@
|
| 1080 |
|
* @return mixed the filtered data, or <b>FALSE</b> if the filter fails. |
| 1081 |
|
* @since 5.2.0 |
| 1082 |
|
*/ |
| 1083 |
|
public static function filter_var($variable, int $filter = FILTER_DEFAULT, $options = null) |
| 1084 |
|
{ |
| 1085 |
|
if (3 > \func_num_args()) { |
| 1086 |
|
$variable = \filter_var($variable, $filter); |
| 1087 |
|
} else { |
| 1088 |
|
$variable = \filter_var($variable, $filter, $options); |
| 1089 |
|
} |
| 1090 |
|
|
| 1091 |
|
return self::filter($variable); |
| 1092 |
|
} |
| 1093 |
|
|
| 1094 |
|
/** |
| 1095 |
|
* "filter_var_array()"-wrapper with normalizes to UTF-8 NFC, converting from WINDOWS-1252 when needed. |