Fix image rotation on upload
What does it do?
Added an Exif check for edited images and if the have been Orientated. If Orientated, make sure the image is also saved with the correct data.
Why is it needed?
Certain software doesn't save the edit data correctly which will cause rotated imaged to be reverted back after upload.
How to test
Rotate an image, upload it to the site, check if the image is still in correct position.
Related issue(s)/PR(s)
Resolves: #16785 and also resolves https://github.com/modxcms/revolution/pull/15484
Hey, really nice! About once a year I get a client asking me why the photo they just uploaded is rotated on their website.
@MrRoco - Can you specify at least one software package that does not correctly save the data? That'll help in testing the PR.
@MrRoco - Can you specify at least one software package that does not correctly save the data? That'll help in testing the PR.
Hello, it's really random, most of the times its from clients who use windows.
@MrRoco - Can you specify at least one software package that does not correctly save the data? That'll help in testing the PR.
It used to happen on phones all the time when people uploaded directly. It's why it's a built in helper on my MODX Buddy package (along with resizing).