[Solved] How isset() works?


isset($var) checks that the variable is defined in the current scope and its value is not null. Some examples:

<?php 
  isset($var); //false
?>

<?php 
  $var = null;
  isset($var); //false
?>

<?php 
  $var = "some string";
  isset($var); //true
?>


<?php 
  $var = "";
  isset($var); //true
?>


<?php 
  $var = false;
  isset($var); //true
?>

solved How isset() works?