function block_custom_block_delete_submit
block_custom_block_delete_submit($form, &$form_state)
Form submission handler for block_custom_block_delete().
See also
File
- modules/block/block.admin.inc, line 635
- Admin page callbacks for the block module.
Code
function block_custom_block_delete_submit($form, &$form_state) { db_delete('block_custom') ->condition('bid', $form_state['values']['bid']) ->execute(); db_delete('block') ->condition('module', 'block') ->condition('delta', $form_state['values']['bid']) ->execute(); db_delete('block_role') ->condition('module', 'block') ->condition('delta', $form_state['values']['bid']) ->execute(); drupal_set_message(t('The block %name has been removed.', array('%name' => $form_state['values']['info']))); cache_clear_all(); $form_state['redirect'] = 'admin/structure/block'; return; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!block!block.admin.inc/function/block_custom_block_delete_submit/7.x