You are here

function xmlsitemap_custom_delete_link_form_submit in XML sitemap 7.2

Same name and namespace in other branches
  1. 6.2 xmlsitemap_custom/xmlsitemap_custom.admin.inc \xmlsitemap_custom_delete_link_form_submit()

Delete Link Form Submit.

File

xmlsitemap_custom/xmlsitemap_custom.admin.inc, line 214
Administrative page callbacks for the xmlsitemap_custom.

Code

function xmlsitemap_custom_delete_link_form_submit($form, &$form_state) {
  $link = $form_state['values']['link'];
  xmlsitemap_link_delete('custom', $link['id']);
  drupal_set_message(t('The custom link for %loc has been deleted.', array(
    '%loc' => $link['loc'],
  )));
  watchdog('xmlsitemap', 'The custom link for %loc has been deleted.', array(
    '%loc' => $link['loc'],
  ), WATCHDOG_NOTICE);
  $form_state['redirect'] = 'admin/config/search/xmlsitemap/custom';
}