Tracker: Bugs

5 [exif] bad character sets interpretation - ID: 1546475
Last Update: Settings changed ( ckdake )

I have a character set convertion problem with the Exif
module. As I am French, I am using accentued char is
these fields but the exif module is reading incorrectly
these chars , probably due to encoding (ISO-8851-15).

http://gallery.menalto.com/node/39271
http://gallery.menalto.com/node/45981

You will find in attachment a jpg file with the problem
the real comment is :
La Tremblade - Croisière sur la Seudre
The "è" in the word "Croisière" becomes "Croisi?re"
when read by g2.


I have applied the temporary fix below :
ExifHelper.class, line 440:

function getExifValue(&$source, $keyPath) {
$key = array_shift($keyPath);
if (!isset($source[$key])) {
return null;
}

if (empty($keyPath)) {
$tmpdata=str_replace("\0", '', $source[$key]);

return
mb_convert_encoding($tmpdata,"UTF-8",mb_detect_encoding($tmpdata
, 'UTF-8, ISO-8859-15'));
}

return ExifHelper::getExifValue($source[$key], $keyPath);
}


Olivier Printemps ( ospring ) - 2006-08-25 07:52

5

Open

None

Nobody/Anonymous

None

Gallery 2

Public


Comment ( 1 )

Date: 2007-12-15 18:55
Sender: lapinoo


I came accross the same bug.

One detail however : special characters were not replaced by a "?" but
with nothing.


Attached File ( 1 )

Filename Description Download
img75_2.jpg Photo with an exif comment bad interpreted by G2 Download

Changes ( 3 )

Field Old Value Date By
summary [G2][Exif] bad character sets interpretation 2008-10-24 20:36 ckdake
category_id deleted 2008-10-24 19:38 ckdake
File Added 190597: img75_2.jpg 2006-08-25 07:52 ospring