Well, I can't guarantee that all LDAP servers have case insensitive
attribute names, but I do believe they are supposed to. :)

The problem I seemed to be having was in the way the list and show
retrieved records and used '*_field'.

In my configuration, I was using 'displayName' in the 'search_fields' as
well as for the 'name_field'. Changing the case in 'search_fields' had
absolutely no effect on the results. I was able to use displayname and
displayName interchangeably.

The problem was in 'name_field'. If I specified 'displayname' for
'name_field', the list following a search would show names, but if you
click on a name in the list, the name would be empty in the details. If
I specified 'displayName' for 'name_field', then the list would have
empty entries, but clicking on one of those empty entries would show the
full contact details including the name.

I did try strtolower in __construct(), but that only replicated one of
the issues described above (I can't remember for sure which one now).

Honestly, I'm not sure why there is a difference in case-usage between
the listing of records and displaying details of a specific record. As
it is, it took me quite some time to track down the "filtering" effect
of _ldap2result (I have admitted, and admit again here, that I am not a
professional programmer or debugger :) ).

Kyle


A.L.E.C wrote:
> Terminal Addict wrote:
> 
>>      foreach ($this->fieldmap as $rf => $lf)
>>      {
>>        if ($rec[$lf]['count'])
>>          $out[$rf] = $rec[$lf][0];
>>        elseif ($rec[strtolower($lf)]['count'])
>>          $out[$rf] = $rec[strtolower($lf)][0];
> 
> Ok. Can't we do this (strtolower) in __construct()?
> 
> The main question is: Have all ldap servers case insensitive attribute 
> names?
> 


_______________________________________________
List info: http://lists.roundcube.net/dev/

Reply via email to