There may be 5 or 105 rendered rows, and at the bottom I need a total of that variable.
ie:
5
10
25
total: 40.
I have ready about "+=" but can't get it to work.
There will be about 10 other 'sums' to do as well.
I've so far got this:
Code: Select all
<td>£$row->total</td>
<td>£$row->unpaidbills</td>
<td>$row->timespent</td>
<td>£$row->estimate</td>
<td>$row->currentpos<br/>";
$totalsum += $row->total;
echo "$totalsum</td>
</tr>
";Can anyone help please?
Simon