Reputation: 458
I'm building a gallery for my website with Fancybox 2. The problem is, that it rotates my images counter-clockwise when they have vertical alignment.
Here is the code that I'm using to start fancybox:
$(".fancybox").fancybox({
openEffect : 'none',
loop : true,
preload: 3,
closeEffect : 'none',
helpers : {
title: {
type: 'inside'
}
}
});
And also, I have found no autorotate option for the plugin. What can I do to make photos look right?
Upvotes: 0
Views: 3423
Reputation: 1287
EXIF meta data is given to the image by the camera/phone when the photo is taken.
JPG files stores this data and it confused fancybox sometimes. The simplest solution is to resave the image as a PNG and fancybox will display it properly.
Upvotes: 1
Reputation: 10141
See the problem here is that the original photo itself is in the horizontal form. If you want to display this photo correctly do one thing, open this photo with some very good image viewer software and perform rotation on it and save the new rotated image. Now open the same newly generated rotated image in the fancybox, you will get it displayed correctly this time !
Upvotes: 1