Extending LDAPuserdata (Adding New Attributes)

You can easily add new attributes to be saved on the LDAP server. Say you want to add 'squirrelmail_variable_name' in the preferences, and name the corresponding LDAP attribute ldapAttributeName. Simply:

  1. Add an entry like 'ldapattributename' => 'squirrelmail_variable_name' in $ldap_attributes array in config.php.
  2. If it is a boolean attribute, add the same thing in $boolean_attrs array.
  3. Add a default value for it, in $prefs_default array, as in 'squirrelmail_variable_name' => 2.
  4. Of course, add it to your LDAP schema!