I would like to get the value of the form(eg: a label text - field name: test_label). But I don't know how to get the value on the events, and I am using the custom code. Is that just easy to do it?😟 😟 😟 😟 😟
Forums
How to get the value of the form?
When I use the following code in the custom code, it's not work.
Is anything wrong? "$Donation" is the form name and the "Donation2" is the label text field name.
Thanks!!
Is anything wrong? "$Donation" is the form name and the "Donation2" is the label text field name.
Thanks!!
<script>
function getValue()
{
var x = $Donation->data['Donation2'];
alert(x);
}
</script>
<body onload="getValue()">
Hi yuna_1109,
That's a mixed up mess of PHP and JavaScript. What do you actually need to do?
Bob
PS $form->data stays as $form->data not $Donation->data.
That's a mixed up mess of PHP and JavaScript. What do you actually need to do?
Bob
PS $form->data stays as $form->data not $Donation->data.
Hi yuna_1109,
That's a mixed up mess of PHP and JavaScript. What do you actually need to do?
Bob
PS $form->data stays as $form->data not $Donation->data.
Hello,
maybe he should try rename one of the fields ?
There is no problem if the form name and the label text field name are almost similar ?
This topic is locked and no more replies can be posted.