function content_multigroup_add_more_submit in Content Construction Kit (CCK) 6.3
Submit handler to add more choices to a content form. This handler is used when JavaScript is not available. It makes changes to the form state and the entire form is rebuilt during the page reload.
1 string reference to 'content_multigroup_add_more_submit'
- content_multigroup_add_more in modules/
content_multigroup/ content_multigroup.node_form.inc - Add AHAH add more button, if not working with a programmed form.
File
- modules/
content_multigroup/ content_multigroup.node_form.inc, line 737 - Implementation of node edit functions for content multigroup.
Code
function content_multigroup_add_more_submit($form, &$form_state) {
// Set the form to rebuild and run submit handlers.
node_form_submit_build_node($form, $form_state);
$group_name = $form_state['clicked_button']['#group_name'];
$type_name = $form_state['clicked_button']['#type_name'];
// Make the changes we want to the form state.
if (isset($form_state['clicked_button']['#item_count'])) {
$form_state['item_count'][$group_name] = $form_state['clicked_button']['#item_count'] + 1;
}
}