Can't seem to figure out this one out...
I tried this, see below :
while ($row=mysql_fetch_array($results)) {
echo ("$row[Name]");
if ($row) {
echo (",");
} else {
echo (".");
}
}
I just want to display the results as
Name1, Name2, Name3, Name4.
the last record should end with a dot and not a comma. How does one know that the record is the last one in the array?
Can anyone please explain to me?
Thanks