You are here

function block_admin_configure_validate in Drupal 6

Same name and namespace in other branches
  1. 4 modules/block.module \block_admin_configure_validate()
  2. 5 modules/block/block.module \block_admin_configure_validate()
  3. 7 modules/block/block.admin.inc \block_admin_configure_validate()

File

modules/block/block.admin.inc, line 265
Admin page callbacks for the block module.

Code

function block_admin_configure_validate($form, &$form_state) {
  if ($form_state['values']['module'] == 'block') {
    if (empty($form_state['values']['info']) || db_result(db_query("SELECT COUNT(*) FROM {boxes} WHERE bid != %d AND info = '%s'", $form_state['values']['delta'], $form_state['values']['info']))) {
      form_set_error('info', t('Please ensure that each block description is unique.'));
    }
  }
}