i'm using this script:
$ttl=0;
$mysql...
while($row=...)
{
$total=number_format($row[quantity]*$row[price], 2, '.', '\'');
$ttl += $total;
echo"$row[quantity] - $row[price] - $total";
}
echo"Total: $ttl";
This script works ONLY if i leave the "number_format" away.
Else I get this:
10 - €350.00 - €3'500.00
1 - €350.00 - €350.00
10 - €5.00 - €50.00
10 - €20.00 - €200.00
Total: €$ttl (€603) ?????
What the Script Counts:
350+50+200 = 600 and the 3500 he's taken it as an "3"
Why 3 and not 3500?
If I take the number_format away the script works, but the number will not be formated -> €1400 and I want it as €1'400,00
Does someone know the answer?