$vartest = 0;
if ($vartest == "This can't be TRUE") { echo "But it is TRUE"; }
>> But it is TRUE
By mistake I made a wrong declaration somewhere in my program, and discovered this strange behaviour.
I used $vartest = “” most of the time, but somewhere $vartest = 0 slipped into the program.
Because I spent hours to find the error I’m posting this just for awareness.
Just one question. The variable $vartest is empty, but why does PHP find this TRUE ?