function path_admin_form_submit
7.x path.admin.inc | path_admin_form_submit($form, &$form_state) |
6.x path.admin.inc | path_admin_form_submit($form, &$form_state) |
Save a new URL alias to the database.
File
- drupal-6.x/
modules/ path/ path.admin.inc, line 149 - Administrative page callbacks for the path module.
Code
function path_admin_form_submit($form, &$form_state) {
// Language is only set if locale module is enabled
path_set_alias($form_state['values']['src'], $form_state['values']['dst'], isset($form_state['values']['pid']) ? $form_state['values']['pid'] : 0, isset($form_state['values']['language']) ? $form_state['values']['language'] : '');
drupal_set_message(t('The alias has been saved.'));
$form_state['redirect'] = 'admin/build/path';
return;
}