FRM Math Not Summing

By: Sean Bell | Asked: 04/26/2024
ForumsCategory: General questionsFRM Math Not Summing
Sean Bell asked 3 weeks ago

When using the "Send API data" form action I have a field where I want to send the sum of the values of 3 other fields.

[frm-math] [formField1]+[formField2]+[formField3] [/frm-math]

I am populating each field with 0 using JS on the initial page load, and have another counter function that updates the values throughout the form fill.

For some reason, even though I am populating the fields with 0 as a value, the API field only passes through to my CRM if the values in all three fields are not 0 or null.

null + null + null .... Does not pass through

0 + 0 + 0 .... Does not pass through

1 + 0 + 0 .... Does not pass through

1 + 1 + 1 .... DOES pass through (value = 3)  

Any ideas what is causing this and how I can get the second and third scenarios above to pass through correctly as 0 and 1?  

1 Answers
Victor Font answered 3 weeks ago
Fields absent of values are not processed by Formidable. Null is an invalid value. If you want all 3 fields to process all the time, set a default value of zero.
Sean Bell replied 3 weeks ago

Hi Victor - thanks for such a rapid response - much appreciated.

Unfortunately i've already tried this and it doesn't work. I've tried both setting the fields default value to 0 within Formidable and am now also populating the fields with 0 using Javascript on page load. Both to no avail.

Bobby Clapp replied 3 weeks ago

If the FF API is passing the values correctly (maybe confirm with postman) and the CRM isn't taking the values, I'd point the finger at the CRM.

Making the Best WordPress Plugin even better - Together

Take on bigger projects with confidence knowing you have access to an entire community of Formidable Experts and Professionals who have your back when the going gets tough. You got this!
Join the community
crossarrow-right