function breakpoints_admin_breakpoint_group_duplicate_form_submit in Breakpoints 7
Duplicate group form submit.
File
- ./
breakpoints.admin.inc, line 1212 - Breakpoints - admin settings
Code
function breakpoints_admin_breakpoint_group_duplicate_form_submit($form, &$form_state) {
$machine_name = $form_state['values']['machine_name'];
$name = $form_state['values']['name'];
$src_group = $form_state['#src_group'];
if ($src_group) {
breakpoints_breakpoints_group_duplicate($src_group, $name, $machine_name);
// Clear the Ctools export API cache.
ctools_include('export');
ctools_export_load_object_reset('breakpoint_group');
menu_rebuild();
$form_state['redirect'] = 'admin/config/media/breakpoints/groups/' . $machine_name;
drupal_set_message(t('The new group have been created'));
}
}