A custom content type that we built recently had multiple fields which accepted unlimited values. Some of these fields were grouped together and expected to accept values together.
The fix to this problem is rather simple. Simulate clicking on individual "Add More" buttons. We generalized this idea and create a jQuery plugin to facilitate this on any group of multi-value fields inside a container. This is supported for Drupal 6 & 7. Use the plugin from the approriate github branch from: https://github.com/nkmani/group-add-more (1.0 is for D6 and 2.0 is for D7).
To use this plugin:
Include the jquery.group-add-more.js file (both development as well as minified versions are available) in your theme.
Include the javascript snippet to attach the plugin to the container that has the add-more buttons.
The rendered group field would look like as shown below.
Group Add More: Simulate clicking on group of multi-value fields
A custom content type that we built recently had multiple fields which accepted unlimited values. Some of these fields were grouped together and expected to accept values together.
The fix to this problem is rather simple. Simulate clicking on individual "Add More" buttons. We generalized this idea and create a jQuery plugin to facilitate this on any group of multi-value fields inside a container. This is supported for Drupal 6 & 7. Use the plugin from the approriate github branch from: https://github.com/nkmani/group-add-more (1.0 is for D6 and 2.0 is for D7).
To use this plugin:
Include the jquery.group-add-more.js file (both development as well as minified versions are available) in your theme.
Include the javascript snippet to attach the plugin to the container that has the add-more buttons.
The rendered group field would look like as shown below.