Changes

Jump to: navigation, search

MailNews:LDAP Address Books

2,231 bytes added, 22:06, 8 March 2007
Initial text on how to override the default LDAP Address Book schema.
The default settings are specified in a [[MailNews:Mozilla LDAP Address Book Schema|defined schema]], currently in an alpha version. Setting up a LDAP server with this schema, and setting up the address book (Thunderbird or SeaMonkey) to talk to that LDAP server will enable all fields to work correctly.
TODO== Overriding the default schema for LDAP address books == As of SeaMonkey 1.0 and Thunderbird 1.5 it is possible to override some aspects of the default LDAP schema for address books. This can either be done for all LDAP address books, or for individual ones. === Globally overriding the default LDAP schema === In preferences (about:config/prefs.js) there are a set of preferences prefixed by "ldap_2.servers.default.attrmap.". For example: Detail how  <pre>pref("ldap_2.servers.default.attrmap.FirstName", "givenName");pref("ldap_2.servers.default.attrmap.LastName", "sn,surname");pref("ldap_2.servers.default.attrmap.DisplayName", "cn,commonname");pref("ldap_2.servers.default.attrmap.NickName", "mozillaNickname,xmozillanickname");pref("ldap_2.servers.default.attrmap.PrimaryEmail", "mail");pref("ldap_2.servers.default.attrmap.Company", "o,company");</pre> By changing these values (comma-separated lists), you are able to override the default mapping for address book attributes. Taking the Company case, it is by default set to look up the "o" attribute first, if it doesn't find it to be present, it will look up the "company" attribute instead. Note that when searching for items, the address book will only search for the first attribute, i.e. "o" in this case. So changing "ldap_2.servers.default.attrmap.Company" to "organization,o,company" will cause the address book when searching for Companies, to look at the "organization" attribute, and to prioritise the organization attribute when pulling out values to display. === Overriding individual LDAP Address Book Schemas === In a similar manner to globally overriding the LDAP Address Book schema , it can also be overridden for individual address books. # Create a LDAP address booksbook in SeaMonkey/Thunderbird.# Exit SeaMonkey/Thunderbird# Look in prefs.js for ldap_2.servers.xxx.description - The value should match the name you entered, note the xxx value.# For the attribute(s) you wish to override, set up new preferences of the form: ldap_2.servers.xxx.attrmap.attribute (where attribute matches one of the global attributes) and set the value to whatever you wish for that address book.# Save prefs.js and restart SeaMonkey/Thunderbird - you should find that the schema override works only for that particular address book.
Canmove, confirm, emeritus
3,627
edits

Navigation menu