[kronolith] ISO-8859-1: exporting calendar containing french accents

Jan Schneider jan at horde.org
Fri Mar 9 17:43:31 UTC 2007


Zitat von Jan Schneider <jan at horde.org>:

> Zitat von Patrick ABIVEN <patrick.abiven at apitech.fr>:
>
>> Hello
>> We are using ISO-8859-1 (in NLS.php), and exporting calendar
>> containing events with french accents. In the .ics file, the french
>> accents are kept with no specific encoding (the .ics file is not
>> utf-8). So when importing this file into another calendar, it will
>> produce events with accents transformed.
>>
>> A workaround we found, it to force an utf-8 transformation when
>> exporting the calendar.
>> /lib/Horde/iCalendar.php, in _exportvData() function. So the
>> exported .ics file is utf-8 encoded.
>>
>> $value = $attribute['value'];
>> + if ($name =='LOCATION' || $name == 'SUMMARY' || $name ==
>> 'DESCRIPTION' || $name == 'CATEGORIES') {
>> + $value = String::convertCharset($value, NLS::getCharset(), 'utf-8');
>> + }
>> switch ($name) {
>> ...
>> Thanks for any advise.
>
> Can you try this patch please:
> http://cvs.horde.org/diff.php?f=turba%2Flib%2FDriver.php&r1=1.125&r2=1.126&t=unified

Ignore that, this one was for Turba.

Jan.

-- 
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/



More information about the kronolith mailing list