|
@@ 1041-1050 (lines=10) @@
|
| 1038 |
|
* returns <b>FALSE</b> if the variable is not set and <b>NULL</b> if the filter fails. |
| 1039 |
|
* @since 5.2.0 |
| 1040 |
|
*/ |
| 1041 |
|
public static function filter_input(int $type, string $variable_name, int $filter = FILTER_DEFAULT, $options = null) |
| 1042 |
|
{ |
| 1043 |
|
if (4 > \func_num_args()) { |
| 1044 |
|
$var = \filter_input($type, $variable_name, $filter); |
| 1045 |
|
} else { |
| 1046 |
|
$var = \filter_input($type, $variable_name, $filter, $options); |
| 1047 |
|
} |
| 1048 |
|
|
| 1049 |
|
return self::filter($var); |
| 1050 |
|
} |
| 1051 |
|
|
| 1052 |
|
/** |
| 1053 |
|
* "filter_input_array()"-wrapper with normalizes to UTF-8 NFC, converting from WINDOWS-1252 when needed. |
|
@@ 1159-1168 (lines=10) @@
|
| 1156 |
|
* @return mixed the filtered data, or <b>FALSE</b> if the filter fails. |
| 1157 |
|
* @since 5.2.0 |
| 1158 |
|
*/ |
| 1159 |
|
public static function filter_var($variable, int $filter = FILTER_DEFAULT, $options = null) |
| 1160 |
|
{ |
| 1161 |
|
if (3 > \func_num_args()) { |
| 1162 |
|
$variable = \filter_var($variable, $filter); |
| 1163 |
|
} else { |
| 1164 |
|
$variable = \filter_var($variable, $filter, $options); |
| 1165 |
|
} |
| 1166 |
|
|
| 1167 |
|
return self::filter($variable); |
| 1168 |
|
} |
| 1169 |
|
|
| 1170 |
|
/** |
| 1171 |
|
* "filter_var_array()"-wrapper with normalizes to UTF-8 NFC, converting from WINDOWS-1252 when needed. |