miromannino / Justified-Gallery

Javascript library to help creating high quality justified galleries of images. Used by thousands of websites as well as the photography community 500px.
http://miromannino.github.io/Justified-Gallery/
MIT License
1.69k stars 299 forks source link

Urgent - Please help regarding grid plugin #117

Open xcelpixel opened 9 years ago

xcelpixel commented 9 years ago

Great work! I have a question regarding my requirements. Please click the link below to see the screenshot: http://i57.tinypic.com/302010j.jpg

I am using ACF Justified Grid Plugin by Thomas Basically, i have setup everything as you said above and everything is working fine. Basically, i need 2 version of images side by side left one is small and right one is big but wih the same height.

I don't understand how to set it up? How can i lock 2 sizes for images?

Please help.

Thanks

miromannino commented 9 years ago

I think it is not really possible if you intend it to be "the same image". Suppose we have the same image (e.g. 50x100 px). If you configure JG to have an height of 50px, it resizes the two copies of the same image to be 25x50 px. It can't do different things for the two images.

For me there are two workarounds:

1) you need to have different images: if you want the image A to be bigger, you can copy A and crop it removing some height from the top and the bottom. Then, on the server, you have the image A and the cropped version of A.

2) As in this page: http://miromannino.github.io/Justified-Gallery/performance-tips/ You can specify the dimension of the image. You can specify the right dimension of the image A for the first time, and then you can specify a wrong dimension of the image A the second time. The second time it could crop the image or do something something similar, but I'm not sure.

I hope it helped, Tell me if have other questions