I’ve already covered up with English stackoverflow, but the problem hasn’t been fixed. And here it lies in this: first there was an error, everyone advised to replace $_POST with filter_input(INPUT_POST,"name") .
But now, after compilation, an error is displayed on the page:

Can not use isset () function call (you can use "null! == func ()" instead)

 <?php if(isset( filter_input(INPUT_POST,"name") )){ if (filter_input(INPUT_POST,"name" == "admin") && filter_input(INPUT_POST,'pass' == 'admin')){ header("Location:newpage.php"); } } ?> 
  • one
    What is not understandable in the error? You are trying to check the function on isset ... - fens
  • isset is designed to test the existence of variables. - fens
  • after the header it is better to use exit; - Yura Petrov

1 answer 1

So it is written. And what to replace is also written. Free translation, but technical English you need to learn to understand:

cannot use isset for function result. You can use null! == func () instead

The construction of the isset language (not a function! This is a language construction, and therefore has its own behavior) cannot verify the result of a function. Since the function always returns something (in PHP realities, even return; implicitly returns null), and besides checking a variable for existence, isset also checks for null equality, therefore it is proposed to compare the result of the function with null.