I have an array called as myArr. It contains strings and integers, e.g.
0 st ts 0 0
st 0 0 0 0
For debugging the php script, I'm using Zend Studio. The debug window says that a cell [0][0] contains int 0. BUT the problem is that IF statement returns TRUE.
for ($i = 0; $i < $rows; $i++) {
for ($j = 0; $j < $cols; $j++) {
if ($myArr[$i][$j] == 'ts' || $myArr[$i][$j] == 'st') {
$num++;
}
}
}
UPDATE: I'm running the code in Debug mode in Zend Studio. So, I can see that $num is increasing in each iteration. Also, I can see that cursor goes inside the loop
$numequal to 10?==and===work in PHP.