isset

isset -- determine whether a variable is set

Description

int isset(mixed var);

Returns true if var exists; false otherwise.

If a variable has been unset with unset(), it will no longer be isset().

  1 
  2 $a = "test";
  3 echo isset ($a); // true
  4 unset ($a);
  5 echo isset ($a); // false
  6       

See also empty() and unset().