It seems that there is a problem when syncing from android to a carddav server (in my case owncloud 8.1.1)
Steps to reproduce:
- Modified any contact and change the contact image.
- Sync in android
Result: Contact image is not shown on server and got lost from android’s adressbook
The other way:
- Modified any contact on owncloud server
- Sync in android
Result: Contact image is shown in android
I tried the same steps using “CardDAV-Sync free” by Marten Gajda and this was working. So it is not a problem of android itself
Then I compared both VCARDs and found the difference that may lead to this issue:
-
The working version using “CardDAV-Sync free” sends this as PHOTO tag:
PHOTO;TYPE=JPEG;VALUE=BINARY;ENCODING=B:/9j/4AAQSkZJ[... and some more data ...]
-
The DAVdroid version sends this as PHOTO tag which is not working:
PHOTO:data:image/jpeg;base64,/9j/4AAQSkZJ[... and some more data ...]
The base64 encoded images starts with “/9j”. This is the same in both variants. I pathed my owncloud instance to replace “PHOTO:data:image/jpeg;base64,” by “PHOTO;TYPE=JPEG;VALUE=BINARY;ENCODING=B:” and it worked. So could you please fix this in DAVdroid?
To test the new VCARD, you could use a onlien tool: http://www.proflogic.com/vCard/
SOFTWARE INFORMATION
DAVdroid version: 0.9.0.4 (82)
JB Workarund installed: no
SYSTEM INFORMATION
Android version: 5.1.1
Device: samsung / GT-I8190