I am testing string like so,,
for ($i=0; $i < $numlines;$i++)
{
echo $file[$i].' '.$testLine;
if (strcmp($file[$i],$testLine))
{
echo 'same';
fwrite($fp,$file[$i]);
}
}
when I echo it, it gives me 2 different strings but ALWAYS goes into the echo 'same' code?
strcmp not working right
Moderator: General Moderators
-
slipstream
- Forum Commoner
- Posts: 86
- Joined: Fri Apr 19, 2002 8:53 am
- Location: Canada
-
slipstream
- Forum Commoner
- Posts: 86
- Joined: Fri Apr 19, 2002 8:53 am
- Location: Canada