while ($row = mysql_fetch_array($result))
{
echo " <tr bgcolor='#CCCCCC'>\n";
echo " <td><div align='center'>$row[id]</div></td>\n";
echo " <td><div align='center'>$row[date]</div></td>\n";
echo " <td><div align='center'>$row[description]</div></td>\n";
echo " <td><div align='center'>$row[ammount]</div></td>\n";
echo " </tr>\n";
$totalAmount += $row[ammount];
}
echo "<tr><td> </td><td> </td><td> </td><td bgcolor='#CCCCCC' align=center>$totalAmount</td></tr>";
echo "</table>\n";
This is assuming that the value stored within your table is a numeric, and not a formatted string.
If it is a formatted string, you'll have to strip the first character and then perform the sum:
$totalAmount += (float)substr($row[ammount],1);