Hi there,
I am working on a photo gallery and wondered if there was a function that would be able to detect whether an image was a portrait or a landscape image based on width?
Any suggestions?
Thanks
you could write your own
look at getimagesize()
im just a newb, but i thought id have a go.
not tested.
<?php function is_landscape($img) { $arr = getimagesize($img); if ($arr[0] > $arr[1]) { return true; } return false; } ?>