You are here

function advuser_admin_users_submit in Advanced User 5

Perform actions on users

File

./advuser.module, line 586

Code

function advuser_admin_users_submit($form_id, $edit) {
  $operations = advuser_admin_users_operations();
  if ($operations[$edit['operation']][1]) {

    // Execute sql
    $operation = $operations[$edit['operation']][1];
    foreach ($edit['users'] as $uid => $value) {
      if ($value) {
        db_query($operation, $uid);
      }
    }
    drupal_set_message(t('The update has been performed.'));
    drupal_goto('admin/user/advuser');
  }
}