Can Python fix vcard files?

Dotan Cohen dotancohen at gmail.com
Wed Oct 15 13:37:24 EDT 2008


2008/10/15  <skip at pobox.com>:
> Just out of curiosity, are the line endings CRLF perchance?  If so, try
> changing the replace call like this:
>
>    cooked = uncooked.replace('\r\n ', '')
>

Apparently they were CRLF. Actually, I think that is part of the Vcard
spec. Now, it seems that I have a few other problems, but they seem to
be bugs in Kontact.

Thank you very much for the help. I've learned how to open and save
files, and how to search and replace text. I probably could have
gotten that far after a some time googling, but you've probably saved
me a good day or two. Furthermore, I would have had trouble finding
out which libraries to include at the head. Thanks!

-- 
Dotan Cohen

http://what-is-what.com
http://gibberish.co.il
א-ב-ג-ד-ה-ו-ז-ח-ט-י-ך-כ-ל-ם-מ-ן-נ-ס-ע-ף-פ-ץ-צ-ק-ר-ש-ת

ä-ö-ü-ß-Ä-Ö-Ü


More information about the Python-list mailing list