I've been working on webform with a lot of luck. However, I've just hit a road block that I'd like to think there's a simple solution to.

I'm calculating a couple of items, all based on the number of people. In my basic test page, the js calculations work. However, when it comes out in webform, the textareas are renamed and the calculations stop working.

Example:
//
b = document.forms['LAYOUTFORM'].deposit_persons.value;
document.forms['LAYOUTFORM'].deposit_total.value = toDecimals(eval(a * b));
//

In my page based form, the field named "deposit_persons" provides the correct calculation.

When loaded into webform, it's renamed to "submitted[deposit_summary][deposit_persons]" and stops processing. I've tried renaming the js field to "submitted[deposit_summary][deposit_persons]", but no luck.

Can anyone offer a suggestion on the proper name to use?

Thanks.

Comments

quicksketch’s picture

Status: Active » Closed (fixed)

Support on custom code is not provided in the Webform issue queue.