array( 'title' => 'Groups', 'description' => 'Configure LDAP groups to Drupal roles mapping settings.', 'page callback' => 'drupal_get_form', 'page arguments' => array('ldapgroups_admin_settings'), 'access arguments' => array('administer ldap modules'), 'file' => 'ldapgroups.admin.inc', ), 'admin/settings/ldap/ldapgroups/edit' => array( 'title' => 'Groups', 'page callback' => 'drupal_get_form', 'page arguments' => array('ldapgroups_admin_edit', 4, 5), 'type' => MENU_CALLBACK, 'access arguments' => array('administer ldap modules'), 'file' => 'ldapgroups.admin.inc', ), 'admin/settings/ldap/ldapgroups/reset' => array( 'title' => 'Groups', 'page callback' => 'drupal_get_form', 'page arguments' => array('ldapgroups_admin_edit', 4, 5), 'type' => MENU_CALLBACK, 'weight' => 1, 'access arguments' => array('administer ldap modules'), 'file' => 'ldapgroups.admin.inc', ), ); } /** * Implements hook_user(). */ function ldapgroups_user($op, &$edit, &$account, $category = NULL) { switch ($op) { case 'login': require_once(drupal_get_path('module', 'ldapgroups') .'/includes/LDAPInterface.inc'); require_once(drupal_get_path('module', 'ldapgroups') .'/ldapgroups.inc'); ldapgroups_user_login($account); break; } }