If all you have for an image is the URL, you can still find the dimensions:
<?php
list($width, $height, $type, $attr) = getimagesize("url/to/image.jpg");
echo "Image width " . $width;
echo "Image height " . $height;
echo "Image type " . $type;
echo "Attribute " . $attr;
?>
Good snippet. Thanx. My question aside a little bit but… How to set Facebook Canvas Height and Width with jQuery? Native methods do not work sometimes and they only can encrease height but can not decrease.
Hi,
Please look into the PHP code (http://pastebin.com/K076fm5F )and advice how to get Dimension details of Thumbnail image?
The current code doesn’t display dimension details and I’m getting “Specify image dimension” error in gtmetrix page performance check.