$sql ="select rates from room";
$res=@mysql_query($sql);
while ($r= mysql_fetch_assoc($res)) {
print_r($r);
$rs=$r['rates'];
echo"$rs<BR><BR>";
}
this is what i get on my screen:
Array ( [rates] => 65 49 ) 65 49
Array ( [rates] => 58 29 58 29 58 ) 58 29 58 29 58
i need to know how to total each line to give me 114 for the first row and 232 for the 2nd.
i played around with the explode idea but didnt get anywhere...
please help! cheers!