function finder_admin_add_form_submit in Finder 6
Same name and namespace in other branches
- 7 includes/finder.admin.inc \finder_admin_add_form_submit()
Submit function for admin finder add form.
File
- includes/
finder.admin.inc, line 97 - The finder admin screens.
Code
function finder_admin_add_form_submit($form, &$form_state) {
$values =& $form_state['values'];
$finder = (object) array(
'base' => $values['base'],
);
finder_save($finder);
$finder->title = t('Finder !1', array(
'!1' => $finder->finder_id,
));
$finder->path = 'finder/' . $finder->finder_id;
finder_save($finder);
drupal_set_message(t('A finder was added. Configure the finder below.'));
menu_rebuild();
drupal_goto('admin/build/finder/' . $finder->finder_id . '/edit');
}