Commit 68a40e7c authored by Kit Manners's avatar Kit Manners Committed by Imran Hussain

Fix retrieving full name from campus ldap

parent 7a325c26
......@@ -7,7 +7,7 @@ function lookupSID($sid)
$sr = ldap_search($ds, "ou=Active,ou=Resources,o=Swansea", "EDUPERSONTARGETEDID=" . $sid);
$info = ldap_get_entries($ds, $sr);
ldap_unbind($ds);
return ucwords(strtolower($info[0]['givenName'][0] . " " . $info[0]['sn'][0]));
return ucwords(strtolower($info[0]['givenname'][0] . " " . $info[0]['sn'][0]));
}
// lookup addresses from postcodes using the university's website
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment