Hello/Hi/Greetings,
I've built a plugin that reads in metadata from a sidecar file. It's a very simple function, I've added a function to the event `format_exif_data` that basically adds additional key / value pairs to the array. One of these are `xmp_keywords` which I'm pairing in my config for Piwigo to map them to keywords:
// use_exif_mapping: same behaviour as use_iptc_mapping
$conf['use_exif_mapping'] = array(
'date_creation' => 'DateTimeOriginal',
'keywords' => 'xmp_keywords',
);
This is working great - new keywords come in for a photo and are created by Piwigo and associated to that image. My question is that when a keyword gets removed from the photo and I synchronize the album, that function runs and returns the data without that keyword, but Piwigo doesn't remove that keyword from the photo in its database. Is there a way I can have my plugin remove keywords that are no longer included in this list?
Thanks!
Piwigo version: 2.10.2
PHP version: 7.3.17
MySQL version: mysql Ver 15.1 Distrib 10.4.12-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2
Piwigo URL: locally hosted
Offline
Hi :-)
code your plugin ?
Offline
It's a work in progress. I'm currently trying to keep 'keywords' to be in sync. But you can find what I've got so far here: https://github.com/alex-phillips/piwigo … car-plugin
Offline
Is there a different event I should do this work in? Or another one I should tie into? I can't seem to find a list of available events in the docs, so not sure what I can use. Is there a 'handle_metadata_before_write' event or something?
Offline