WordPress size images
-
Dear,
I would like to get width and height of WordPress images with PHP, something like this:
$imgINFO = getimagesize(‘https://smartcommunity.es/wp-content/uploads/2017/03/yyyy.png’);
$imgINFO = getimagesize(‘https://smartcommunity.es/wp-content/uploads/2017/03/Avatar-1.jpg’);
It doesn’t works, I can’t get images information, I only get an empty array.
But, if I use the same way to know image information of external WordPress images it works fine:
$imgINFO = getimagesize(‘https://www.google.es/images/branding/googlelogo/2x/googlelogo_color_120x44dp.png’);
$imgINFO = getimagesize(‘https://www.sport.es/img/logo.png’);
…Someone knows how can I get the WordPress images sizes with PHP ?
Thanks, Xavi
- The topic ‘WordPress size images’ is closed to new replies.