JS error at 20st repeat group

Hi,

I have quote form which uses repeat groups for products with price and quantity. Then I make several js calculations to fill the rest of fields : tax, total, etc...
JS functions are in a form_xx.js file.

Everything works for the 20 first repeat groups... and then I get a js error "SyntaxError: missing ; before statement" in calc-min.js on 21st line.

Do you have an idea where this can come from ?
I don't have any limitation on repeat groups numbers nor in my js function...

Thanks for your help,
Th?o
 
Do you have AJAX enabled on your calcs?

Issues that arise when you have lots of repeats are usually down to restrictions on the number of inputs in a POST or GET, controlled by PHP's max_input_vars setting, which defaults to 1000. Which sounds like a lot, but if you have a group with a lot of elements in it, you can easily hit that limit. Any form submission, or calc AJAX, has to submit every element on your form, including (number of repeats * number of elements in repeat groups), as POST inputs. If you exceed the configured max in PHP, the results are "undefined", as the excess inputs get chopped off, and the effects on our code cannot be predicted.

So try doubling whatever your max_input_vars is set to in your php.ini (don't forget to restart your web server, and check your PHP config in System Information in the J! backend to make sure the change was picked up).

-- hugh
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top