Donate Share

phpLDAPadmin

Tracker: Bugs

5 vcard export broken - ID: 1629976
Last Update: Comment added ( jamincollins )

Specify versions for:
1. phpLDAPadmin - 0.9.8.3
2. Your LDAP server - OpenLDAP 2.2.23
3. Your web server - Apache 2.0.54
4. PHP - 4.3.10
5. Your operating system - Debian sarge

phpldapadmin supports several export formats (LDIF, DSML V.1, VCARD 2.1,
and CSV (Spreadsheet)). This export can before the the base dn, one
level, or an entire subtree.

An export of an entire tree under LDIF, DSML, or CSV shows all objects
within the tree. However with VCARD only a card for the last entry of a
multi entry tree is created. Additionally, the information on the
created card is incorrect.

The only card created for a subtree vcard export (note the presence of
UID, the entry doesn't have one in LDAP):
BEGIN:VCARD
FN:Telasip Support
EMAIL;Internet:support@telasip.com
UID:11
VERSION:2.1
ADR:;;;;;;
END:VCARD

The same entry as an ldif export (note the lack of UID):
dn: cn=Telasip Support,ou=AddressBook,dc=asgardsrealm,dc=net
objectClass: top
objectClass: person
objectClass: organizationalPerson
objectClass: inetOrgPerson
givenName: Telasip
sn: Support
cn: Telasip Support
mail: support@telasip.com

And the same entry as a csv export (again note the lack of UID):
"dn","ou","objectClass","givenName","sn","cn","mail","displayName","telepho
neNumber","facsimileTelephoneNumber","mobile","postalAddress"
"cn=Telasip Support,ou=AddressBook,dc=asgardsrealm,dc=net","","top |
person | organizationalPerson |
inetOrgPerson","Telasip","Support","Telasip
Support","support@telasip.com","","","","",""


Jamin W. Collins ( jamincollins ) - 2007-01-07 16:57

5

Closed

Fixed

Nobody/Anonymous

None

0.9.8

Public


Comments ( 4 )

Date: 2007-01-14 02:30
Sender: jamincollins


That is absolutely perfect. Thank you so much. No more hand edits of the
export. It is ready for immediate use on the iPod as a contact file.
Thanks again.


Date: 2007-01-14 01:25
Sender: wurleyProject AdminAccepting Donations


The FN field is built from the LDAP attribute Common Name, so if you
change your search filter to (cn=*), then you will only get entries with an
FN field... :)


Date: 2007-01-13 21:11
Sender: jamincollins


The patch does seem to correct the subtree export. The export seems to
work pretty well for use on an iPod. I do need to remove entries that
don't have a FN key (such as the LDAP container). I don't know if these
should be filtered from the export or not. Currently, I manually remove
them before saving the file off to the iPod.

Thanks for the rapid resolution.


Date: 2007-01-13 04:10
Sender: wurleyProject AdminAccepting Donations


Actually the UID attribute is not the LDAP uid attribute - it is a unique
identifier for the VCARD. I've changed this to be the DN of the entry,
hopefully that wont cause any trouble.

However, I see that it was not exporting more than 1 entry as you reported
- I've submitted a patch to CVS to fix this. As I dont use VCARDS, can you
please test the patch and let me know if it doesnt work.

You can get the patch here:
http://phpldapadmin.cvs.sourceforge.net/phpldapadmin/phpldapadmin/lib/export_functions.php?r1=1.32.2.8&r2=1.32.2.9&pathrev=BRANCH-0_9_8

I'll close this ticket, but if the patch doesnt work for you, then please
reopen this with some info on why it doesnt work :)

...deon


Attached File

No Files Currently Attached

Changes ( 3 )

Field Old Value Date By
status_id Open 2007-01-13 04:10 wurley
resolution_id None 2007-01-13 04:10 wurley
close_date - 2007-01-13 04:10 wurley