bug 481: Incorrect tag generation in listing.xml for accentuated letters

git-svn-id: http://piwigo.org/svn/branches/branch-1_6@1485 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
rvelices 2006-07-20 23:49:05 +00:00
parent 4593260c97
commit 19fa4408c8

View file

@ -136,7 +136,7 @@ function clean_iptc_value($value)
// remove binary nulls
$value = str_replace(chr(0x00), ' ', $value);
return htmlentities($value);
return $value;
}
function get_sync_iptc_data($file)
@ -154,17 +154,18 @@ function get_sync_iptc_data($file)
{
if ( preg_match('/(\d{4})(\d{2})(\d{2})/', $value, $matches))
{
$iptc[$pwg_key] = $matches[1].'-'.$matches[2].'-'.$matches[3];
$value = $matches[1].'-'.$matches[2].'-'.$matches[3];
}
}
}
if (isset($iptc['keywords']))
if ($pwg_key == 'keywords')
{
// official keywords separator is the comma
$iptc['keywords'] = preg_replace('/[.;]/', ',', $iptc['keywords']);
$iptc['keywords'] = preg_replace('/^,+|,+$/', '', $iptc['keywords']);
$value = preg_replace('/[.;]/', ',', $value);
$value = preg_replace('/^,+|,+$/', '', $value);
}
$iptc[$pwg_key] = htmlentities($value);
}
$iptc['keywords'] = implode(
',',
array_unique(