So, "aantal$i" * inkoop_prijs = Subtotal
And, all Subtotals together = Total
Thanks for your help so far, really appreciate it and that's really some amazing script you posted there, it does calculate immediately when you enter a number in the field "aantal".
But the WHILE loop, looks up all products in my database and then lists it.
So when I open up the page there is more then 1 product listed.
The moment where I get a "NaN" error is when I insert a number in 2 different "aantal" fields. It automatically takes the latest inserted value and only calculates with that number, it doesn't add the previously entered number.
Hope you can help me with this one.
Thanks in advance.