I am dealing with a dynamic form that can potentially provide the user with an unspecified number of checkboxes in an array (category[]).
This causes a few issues.
Issue #1: Hitting the maximum number of POST variables that the browser and/or server allows. This can be solved by using a bit of script and actually posting the array in a single comma separated value.
Issue #2: Browsers getting very slow and / or crashing. One user has over 5000 checkboxes representing categories, which causes Chrome to bug out, Firefox to go very slowly and I dare not try it in IE yet!
I would love some suggestions or ideas on how to solve the second problem!
Regards,
Joel
I discovered that the cause of the lag / slowness was due to a jquery loop which was doing an each() on all inputs to determine if any fields have been changed. Obviously jQuery doesn’t like looping through that many elements.
I stopped the loop from hitting the checkbox list and it’s no longer slow.
It would be nice to be able to grab an array of values of the checkbox list in one hit rather than having to loop through them all!