Ok, sorry this took so long. It’s a remote client and this got shelved for a bit, but I’m back on it now.
To answer your question of why we’re doing it this way (trying to):
It’s because the client uploads a bunch of photos with different aspect ratios and I don’t want stretched/distorted thumbnails depending upon the aspect ratio of the photo in question.
My simple solution to that is to set an IMG tag to be 63 pixels square and then just fill the background with the CE Image processed image of something slightly larger (like 90x90) so that aspect ratio doesn’t matter and the images fill the entire thumbnail space.
Anyways, I can’t get it to work.
Code here:
{property_photos var_prefix="file"} <a href="{file:url}" rel="slideshow" title="{title} pictures"> {exp:ce_img:pair src="{file:url}" max="100" quality="60"} <img src="/images/spacer.png" alt="{title}" width="63" height="63" border="0" /> {/exp:ce_img:pair} </a> {/property_photos}
It’s on this page:
http://www.gregellingson.com/for-sale/luxury-real-estate/2843-bellwind-circle
This is for the images right below the H4 tag that says “Click For Larger Pictures” on the right sidebar.
Any ideas?
This exact same code works perfectly if it reads this way:
{property_photos var_prefix="file"} <a href="{file:url}" rel="slideshow" title="{title} pictures"> {exp:ce_img:pair src="{file:url}" max="100" quality="60"} <img src="{made}" alt="{title}" width="63" height="63" border="0" /> {/exp:ce_img:pair} </a> {/property_photos}
But doing it that way obviously makes the different aspect ratio photos stretched/etc to match the constraints of being within 63x63.
Thanks in advance!!
|