I\'m using a foreach loop to echo out some values from my database, I need to strip the last comma from the last loop if that makes sense.
My loop is just simple, as
$value)
{
$str .= ''.$value['cat_title'].'';
if($len > $i)
{
$str .= ',';
$i = $i+1;
}
}
echo $str;
?>