I’m looking to automatically collect specific metadata from uploaded photos (EXIF data), and store / cache, the data, and have the ability to use the data within MODX.
Example EXIF Data
Here is a list of the particular EXIF data I’m looking to collect / use:
- Focal Length
Just an example of how you might be able to call the data in a chunk…
<div class="d-flex flex-row justify-content-start noselect"> <abbr title="Aperture">ƒ/[[+aperture]]</abbr> <abbr title="Exposure">[[+exposure]]</abbr> <abbr title="Focal Length">[[+focallength]]mm</abbr> <abbr title="ISO">[[+iso]]</abbr> </div>
Initially I built repeatable TVs via MIGX. I have one TV per field (aperture, exposure…), but I have quickly realized that it’s a bit of work to manually lookup and enter each photo’s data; especially since the data is already in the file.
I know I could probably use a snippet to read the data [
exif_read_data();], but this is not cached.
I noticed the MoreGallery premium extra appears to have what I’m looking for, but it also has way more than what I’m looking for. I’m not interested in: galleries, video, cropping, pagination…
I ran across this post from ancient times. It sounds like @gissirob came close to coming up with a solution that I’m looking for. I also found this post by @Bruno17. It seems like it might be a good starting point but Ich spreche deutsch nicht.
- MODX v2.7.1
- Apache v2.4.39
- MIGX: 2.12.0-pl
- PHP: 7.3
- MySQL: 5.1
As always, thanks for your help!