Hi. It is rare for me to ever touch php code however, what i am trying to do should be fairly straight forward. I am trying to output the variable "$deposit" to the email template using {deposit}. However, it doesn't work. Nothing is displayed in the email. I have looked at several related forum posts but im none the wiser.
The customer code action is positioned after the handle array action in the onsubmit event.
The mode of the custom code is set to "View"
The variable echo's to the screen after submit so i know it has a value.
Below is my code...
Any ideas what i am doing wrong?
The customer code action is positioned after the handle array action in the onsubmit event.
The mode of the custom code is set to "View"
The variable echo's to the screen after submit so i know it has a value.
Below is my code...
<?php
$pkg_selected = $form->data['package_selected'];
$num_of_persons = $form->data['persons'];
$spa_booking_total = $pkg_selected * $num_of_persons;
$deposit = 2000;
$deposit = $num_of_persons * $deposit;
echo $deposit;
?>
Any ideas what i am doing wrong?