[Tickets #5979] (whitespace-)trimming of mapped attributes

bugs at bugs.horde.org bugs at bugs.horde.org
Sun Dec 9 14:11:17 UTC 2007


DO NOT REPLY TO THIS MESSAGE. THIS EMAIL ADDRESS IS NOT MONITORED.

Ticket URL: http://bugs.horde.org/ticket/?id=5979
-----------------------------------------------------------------------
 Ticket             | 5979
 Created By         | xk3 at mompl.org
 Summary            | (whitespace-)trimming of mapped attributes
 Queue              | Turba
 Version            | 2.2-RC1
 Type               | Enhancement
 State              | New
 Priority           | 1. Low
 Owners             | 
-----------------------------------------------------------------------


xk3 at mompl.org (2007-12-09 06:11) wrote:

Mapping attributes from multiple hash values can generate hideous results
if some of the attributes are not set. Example:

'name' => array('fields' => array('firstname', 'lastname'),
                          'format' => '%s %s', 
                          'attribute' => 'cn'),

If firstname is not set, cn becomes " Lastname"  with a leading space.

Would be nice if mapped attributes get trimmed afterwards, maybe even on
multiple whitespaces within the string. Yes, there cannot be a general trim
rule, but maybe another map parameter just for the (common?) whitespace
separation?



More information about the bugs mailing list