You are here

function simple_access_page_overview_submit in Simple Access 5.2

Same name and namespace in other branches
  1. 6.2 simple_access.admin.inc \simple_access_page_overview_submit()
  2. 7.2 simple_access.admin.inc \simple_access_page_overview_submit()

File

./simple_access.module, line 571
This module allows administrators to make nodes viewable by specific 'access groups'. Each access group can contain any number of roles. If a node is not assigned to any access groups, it will remain viewable by all users.

Code

function simple_access_page_overview_submit($form_id, $form_values) {
  foreach ($form_values['groups'] as $gid => $group) {
    db_query('UPDATE simple_access_groups SET weight = %d WHERE gid = %d', $group['weight'], $gid);
  }
}