diff --git a/www/account_manager/groups.php b/www/account_manager/groups.php index ea15605..fbbe471 100644 --- a/www/account_manager/groups.php +++ b/www/account_manager/groups.php @@ -76,14 +76,24 @@ render_js_username_check(); - + - + + \n \n \n"; diff --git a/www/account_manager/index.php b/www/account_manager/index.php index f939f00..573ebda 100644 --- a/www/account_manager/index.php +++ b/www/account_manager/index.php @@ -53,7 +53,8 @@ $people = ldap_get_user_list($ldap_connection);
  - + +
Group name
$group
@@ -64,7 +65,17 @@ $people = ldap_get_user_list($ldap_connection); - + + $attribs){ diff --git a/www/account_manager/new_user.php b/www/account_manager/new_user.php index c604e79..f7bacf1 100644 --- a/www/account_manager/new_user.php +++ b/www/account_manager/new_user.php @@ -82,24 +82,24 @@ if (isset($_GET['account_request'])) { $givenname[0]=filter_var($_GET['first_name'], FILTER_SANITIZE_FULL_SPECIAL_CHARS); $new_account_r['givenname'] = $givenname; - $givenname['count'] = 1; + unset($new_account_r['givenname']['count']); $sn[0]=filter_var($_GET['last_name'], FILTER_SANITIZE_FULL_SPECIAL_CHARS); - $new_account_r['sn'][0] = $sn; - $sn['count'] = 1; + $new_account_r['sn'] = $sn; + unset($new_account_r['sn']['count']); - $uid[0] = generate_username($givenname,$sn); - $new_account_r['uid'][0] = $uid; - $uid['count'] = 1; + $uid[0] = generate_username($givenname[0],$sn[0]); + $new_account_r['uid'] = $uid; + unset($new_account_r['uid']['count']); if ($ENFORCE_SAFE_SYSTEM_NAMES == TRUE) { - $cn[0] = "$givenname$sn"; + $cn[0] = $givenname[0] . $sn[0]; } else { - $cn[0] = "$givenname $sn"; + $cn[0] = $givenname[0] . " " . $sn[0]; } $new_account_r['cn'] = $cn; - $cn['count'] = 1; + unset($new_account_r['cn']['count']); $mail[0]=filter_var($_GET['email'], FILTER_SANITIZE_EMAIL); if ($mail[0] == "") { @@ -112,7 +112,7 @@ if (isset($_GET['account_request'])) { $disabled_email_tickbox = FALSE; } $new_account_r['mail'] = $mail; - $mail['count'] = 1; + unset($new_account_r['mail']['count']); } @@ -121,7 +121,6 @@ if (isset($_POST['create_account'])) { $password = $_POST['password']; $new_account_r['password'][0] = $password; $account_identifier = $new_account_r[$account_attribute][0]; - $this_cn=$cn[0]; $this_mail=$mail[0]; $this_givenname=$givenname[0]; @@ -310,7 +309,7 @@ $tabindex=1;
-
+
diff --git a/www/account_manager/show_user.php b/www/account_manager/show_user.php index 1ab9cf0..63cd96a 100644 --- a/www/account_manager/show_user.php +++ b/www/account_manager/show_user.php @@ -18,8 +18,10 @@ $to_update = array(); if ($SMTP['host'] != "") { $can_send_email = TRUE; } else { $can_send_email = FALSE; } -$LDAP['default_attribute_map']["uidnumber"] = array("label" => "UID"); -$LDAP['default_attribute_map']["gidnumber"] = array("label" => "GID"); +if ($SIMPLE_INTERFACE == FALSE) { + $LDAP['default_attribute_map']["uidnumber"] = array("label" => "UID"); + $LDAP['default_attribute_map']["gidnumber"] = array("label" => "GID"); +} $LDAP['default_attribute_map']["mail"] = array("label" => "Email", "onkeyup" => "check_if_we_should_enable_sending_email();"); $attribute_map = ldap_complete_account_attribute_array(); diff --git a/www/change_password/index.php b/www/change_password/index.php index dd44f5c..92fd379 100644 --- a/www/change_password/index.php +++ b/www/change_password/index.php @@ -21,8 +21,15 @@ if (isset($_POST['change_password'])) { render_header("$ORGANISATION_NAME account manager - password changed"); ?> -
-

Your password has been changed.

+
+
+
+
Success
+
+ Your password has been updated. +
+
+
-
+
Change your password
diff --git a/www/includes/config.inc.php b/www/includes/config.inc.php index 4f0f14f..f30f661 100644 --- a/www/includes/config.inc.php +++ b/www/includes/config.inc.php @@ -10,7 +10,7 @@ "uid" => array("label" => "System username", "onkeyup" => "check_entity_name_validity(document.getElementById('uid').value,'uid_div'); update_email(); check_email_validity(document.getElementById('mail').value);"), "cn" => array("label" => "Common name", "onkeyup" => "auto_cn_update = false;"), "mail" => array("label" => "Email", "onkeyup" => "auto_email_update = false; check_email_validity(document.getElementById('mail').value);") - ); + ); #Mandatory @@ -23,6 +23,8 @@ #Optional + $SIMPLE_INTERFACE = ((strcasecmp(getenv('SIMPLE_INTERFACE'),'TRUE') == 0) ? TRUE : FALSE); + $LDAP['account_attribute'] = (getenv('LDAP_ACCOUNT_ATTRIBUTE') ? getenv('LDAP_ACCOUNT_ATTRIBUTE') : 'uid'); $LDAP['group_attribute'] = (getenv('LDAP_GROUP_ATTRIBUTE') ? getenv('LDAP_GROUP_ATTRIBUTE') : 'cn'); $LDAP['group_ou'] = (getenv('LDAP_GROUP_OU') ? getenv('LDAP_GROUP_OU') : 'groups'); diff --git a/www/log_in/index.php b/www/log_in/index.php index 4231b41..e7e552c 100644 --- a/www/log_in/index.php +++ b/www/log_in/index.php @@ -50,7 +50,7 @@ else { ?>
-
+
Log in
diff --git a/www/request_account/index.php b/www/request_account/index.php index 65e282c..71b502a 100644 --- a/www/request_account/index.php +++ b/www/request_account/index.php @@ -83,22 +83,31 @@ EoT; include_once "mail_functions.inc.php"; $sent_email = send_email($ACCOUNT_REQUESTS_EMAIL,"$ORGANISATION_NAME account requests",$mail_subject,$mail_body); - if ($sent_email) { - $sent_email_message = " Thank you. The request was sent and the administrator will process it as soon as possible."; - } - else { - $sent_email_message = " Unfortunately the request wasn't sent because of a technical problem."; - } - ?> -
-
-
-
-
+ if ($sent_email) { ?> +
+
+
+
Thank you
+
+ The request was sent and the administrator will process it as soon as possible. +
+
+
+
+ +
+
+
+
Error
+
+ Unfortunately the account request wasn't sent because of a technical issue. +
+
+
-
-
+
Member of