Let's test those comparisons! bar isn't set yet.. ------------------------------------ foo= bar and bar= "" !$bar is TRUE empty($bar) is TRUE $bar=="" is TRUE $bar==0 is TRUE $bar is a string! ** It's an empty string! ** It's still an empty string! ** ------------------------------------ foo= bar and bar= 0 !$bar is TRUE empty($bar) is TRUE $bar=="" is TRUE $bar==0 is TRUE ------------------------------------ foo= bar and bar= "0" !$bar is TRUE empty($bar) is TRUE $bar==0 is TRUE $bar is a string! ------------------------------------ foo= bar and bar= 1 --------------------- Source: ----