You are here

function block_access_admin_display_submit in Block Access 6.2

Same name and namespace in other branches
  1. 6 block_access.module \block_access_admin_display_submit()
  2. 7 block_access.module \block_access_admin_display_submit()
1 string reference to 'block_access_admin_display_submit'
block_access_form_alter in ./block_access.module

File

./block_access.module, line 500

Code

function block_access_admin_display_submit($form, &$form_state) {
  $valid = TRUE;

  // For each of the new values
  foreach ($form_state['values'] as $key => $block) {

    // Ignore non block values
    if (is_array($block) && isset($form[$key]['info'])) {
      if (!block_access_check_submit($form, $key, $block)) {
        $valid = FALSE;
      }
    }
  }
  if ($valid) {

    // Call the real and for true submit function
    block_admin_display_form_submit($form, $form_state);
  }
}