I have a loop:
foreach($_SESSION as $key => $val)
Then at the end i have a variable $dave which holds an integer value.
$dave = number_format($dave,2);
echo “€”.$dave." ".$valuenumber.“
The problem is the variable $dave changes for each loop. I’m looking to get a total of all the $dave’s at the end. Does anyone have an idea how I’d do that? Does the variable name have to be changed each time or something?