Pages: 1
How can I transfer the EXIF:ImageDescription to the MySQL database piwigo_images:comment instead of the IPTC field:2=120?
So far I have transferred the IPTC Fields:2=120 to the MySQL database piwigo_images:comment.
The ‘Plugin Read Metadata’ shows the difference.
The plugin shows
IPTC Fields:2=120 shows a maximum of 1974 characters. This is also a maximum size defined in the IPTC specification.
EXIF Fields:ImageDescription shows 2934 characters. The specification for EXIF:ImageDescription is much larger. My maximum is 3400 characters.
So far, I have set the following in local/config/config.inc.php
<?php Code: $conf['use_iptc'] = true; $conf['use_iptc_mapping'] = array( 'keywords' => '2#025', 'author' => '2#080', 'name' => '2#005', 'comment' => '2#120' ); $conf['show_exif'] = false; $conf['show_iptc'] = true; $conf['show_iptc_mapping'] = array( 'Title' => '2#005', 'Copyright' => '2#116' ); ?>
Last edited by Otto_Riehl (2024-05-14 18:24:05)
Offline
Remove the comment mapping so use_iptc_mapping is
$conf['use_iptc_mapping'] = array( 'keywords' => '2#025', 'author' => '2#080', 'name' => '2#005' );
and add
$conf['use_exif'] = true; $conf['use_exif_mapping'] = array( 'date_creation' => 'DateTimeOriginal', 'comment' => 'ImageDescription' );
Untested, but should work. However, note that Exif ImageDescription is defined to hold only ASCII characters, other maybe Latin-1 subset characters might work only by chance, and complying software may write the content to the UserComment area instead, which can hold defined encodings ASCII, JIS and Unicode, and undefined PC local encodings (see Exif v2.32 standard), and may not be properly supported when reading plain through PHP exif_read_data() (see docs) but might work with [extension by ddtddt] Read Metadata or [extension by plg] Exiftool Keywords, didn't try.
Offline
erAck wrote:
Remove the comment
Many thanks for the tip.
I am on my way. I'll be home on Thursday. Then I will test the suggestion and report the result. Thank you.
Otto
Offline
erAck wrote:
Remove
Works wonderfully.
Thank you
Offline
Glad to have helped, thanks.
Offline
Pages: 1