Hi..
I'm using a variant of the effervescence theme, and my problem is with the random image function "stretching" any images in portrait orientation/aspect ratio (which are thinner than the random banner)
- i don't want to make the tall-skinny images any bigger because they'll be too tall, and they're fine for normal use
- so is there a way to get a random function to just skip any images that aren't wide enough? (e.g. anything with a width less than 600px)
apologies if this is just obvious..
Thanks in advance for any advice!
Comments
maybe someone else could give me a basic example of how this can be done?
anyway, thanks for your reply! ZP is easily the best php gallery currently in existance.
Where the code reads: ` <?php printHeadingImage(getRandomImages()); ?>` change it to
`<?php <br />
$image = getRandomImages();
while (!is_null($images) && !isLandscape($image)) { $image = getRandomImages(); }
printHeadingImage($image);
?>`
Warning: I have not tried this. Also, there may not be a landscape image.