In CF 4 I have established 3 hidden fields :
paiement_total
code
date
In Custom Code I defined these as :
actes and paiement are defined visible fields.
In my email response the template gives me :
However these field do not populate and stay blank.
Can you help me. The Custom Code is placed before the email action.
Thank you
paiement_total
code
date
In Custom Code I defined these as :
<?php
$code = date("MdHi");
$paiement_total = $actes+$paiement;
$date = date("dmy");
?>actes and paiement are defined visible fields.
In my email response the template gives me :
<tr> <td> Hidden #21
</td>
<td> {date}
</td>
</tr>
<tr> <td> Hidden #19
</td>
<td> {code}
</td>
</tr>
<tr> <td> Hidden #15
</td>
<td> {paiement_total}
</td>
</tr>However these field do not populate and stay blank.
Can you help me. The Custom Code is placed before the email action.
Thank you
Hi Skirsch,
I think that the Custom Code needs to be
Bob
I think that the Custom Code needs to be
<?php
$form->data['code'] = date("MdHi");
$form->data['paiement_total'] = $actes+$paiement;
$form->data['date'] = date("dmy");
?>Bob
Thanks,
Lines 1 and 3 work fine, however line 2 is returning a zero instead of the sum. When I call {actes} or{paiement} separately I get their value but the sum is not working. Any idea ?
Lines 1 and 3 work fine, however line 2 is returning a zero instead of the sum. When I call {actes} or{paiement} separately I get their value but the sum is not working. Any idea ?
Hi
actes and paiements were define as Field Names in radio boxes. $paiement has a choice of 4 values assigned and $actes is one value assigned. When I call up these fields individually in Thank You or Email actions their values show up. It is when I try to have the sum + that I only get 0.
$form->data['paiement_total'] = $paiement + $actes;
If I change the expression to include only $paiement (or only $actes) {paiement_total} returns nothing. If I place a number value I get the number. And as I said above {paiement} or {actes} gives its value.
I do not know where the php scripts are written on the interior of Joomla. So I am lost as how to resolve this remaining issue and get my payment form on line.
Thank you
actes and paiements were define as Field Names in radio boxes. $paiement has a choice of 4 values assigned and $actes is one value assigned. When I call up these fields individually in Thank You or Email actions their values show up. It is when I try to have the sum + that I only get 0.
$form->data['paiement_total'] = $paiement + $actes;
If I change the expression to include only $paiement (or only $actes) {paiement_total} returns nothing. If I place a number value I get the number. And as I said above {paiement} or {actes} gives its value.
I do not know where the php scripts are written on the interior of Joomla. So I am lost as how to resolve this remaining issue and get my payment form on line.
Thank you
Hi SKirsch,
If they are form values you need to get them from the results
Bob
If they are form values you need to get them from the results
<?php
$paiement = $form->data['paiement'];
$actes= $form->data['actes'];
$form->data['paiement_total'] = $paiement + $actes;
?>or<?php
$form->data['paiement_total'] = $form->data['paiement'] + $form->data['actes'];
?>Bob
This topic is locked and no more replies can be posted.
