Ask your WordPress questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

Formidable Form Experts Required (Copying Field Value Conditionally) WordPress


Copying Field value to another field conditionally. Plz see the attached image for details.

I tried this code
<script type="text/javascript">
var val1 = $("#field_iu157").val();
var val2 = $("#field_bclze").val();
if (val2 < val1) {

But the problem is if the user write something on other fields from which 1st field is calculated then this code does not work.

Answers (2)


Reigel Gallarde answers:

you should call $('#field_iu157').trigger('change');

every time you change the value of $('#field_iu157') in your code...

example: $('#field_iu157').val(value).trigger('change'),


Mohamed Ahmed answers:

For best answer, Could you tell me what is the URL of this form?