cant get if logic correct..
| From: | Gregory Machin | Date: | Wed, 15 Aug 2007 13:30:43 +0000 |
| Subject: | cant get if logic correct.. | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-260847@lists.php.net to get a copy of this message | ||
Hi
i have a piece of code that gets info from a comma delimited file,
then gets each value that is to be insterted into the database ....
The variabls must only contain numbers and must not be null ..
but the logic i have is iether not working or there are some hidden
characters creeping in because it is processing the data ... how can i
do this better ?
for($i=2;$i<$arrsize;$i++){
$parts=explode(",",$lines[$i]);
$stnr=$parts[0];
$subj=$parts[1];
$mark=$parts[4];
if (($stnr>"") and ($subj>"") and ($mark>"")){
//do alot of something lol
}
}
--
Gregory Machin