Strip Image Meta Data on File Upload


#1

Silverstripe Version:
4.4.1

Question:

I need to strip the meta data (EXIF) from any image that is being uploaded.
The problem is, that for some reason the orientation of the images are (sometimes) wrong.

I already found this handy function to strip the meta data:

My question is, where do I apply this? In my Image DataObject inside “onAfterUpload”?
Or is there a build in way? Can I extend a hook?

Thank you.


#2

I solved my problem with this awesome package: