I have a hidden field with a value. Since it's a hidden field my value is a string. In my database the value is stored as a decimal field with 2 point precision.
View
<tr class="grand-total">
<th>Total incl. 21% BTW:</th>
<?php $total = number_format($cartTotal, 2, ',', '') ?>
<td><strong class="grey-color">€{{$total}}</strong></td>
</tr>
<input type="hidden" name="total" value={{$total}}>
Controller
When my total is, for example, €10.95, I get €10.00.
Things I have tried:
(float)$request->total
floatval($request->total)
floatval($request->total * 1.00)
But these all return €10.
10,95or10.95?10,95is an invalid designation. Have changed to10.95as only valid reading. Edit pending.