?php $a = array ('test '= 1, 'hello' = NULL); var_dump (isset ($a['test'])); / / TRUE var_dump (isset ($a['foo'])); / / FALSE var_dump (isset ($a['hello'])); / / FALSE / / The key'hello 'equals NULL so is considered unset / / If you want to check for NULL key values then try: var_dump (array_key_exists('hello', $a)); / / TRUE?
?php $a = "test"; echo isset ($a); / / TRUE unset($a); echo isset ($a); / / FALSE ?php $a = "test"; echo isset ($a); / / TRUE unset($a); echo isset ($a); / / FALSE?