ImageOrientationFix
v3.2.1
PHP library to fix image orientation by exif data with thanks to method exif_read_data

composer require jellybellydev/image-orientation-fixuse ImageOrientationFixImageOrientationFixer;
$iof = new ImageOrientationFixer('foo.jpg');
$iof->fix();or
use ImageOrientationFixImageOrientationFixer;
$iof = new ImageOrientationFixer('/path/foo.jpg', '/path/foo_fixed.jpg');
$iof->fix();Dependencies are managed through composer:
$ docker-compose up --build -d
$ docker-compose run php74 composer install
$ docker-compose run php74 composer test
docker-compose run php74 composer cs-fixerPlease refer to the changelog notes.
Thanks to recurser for the image example