proctk Posted July 19, 2007 Share Posted July 19, 2007 probably an easy question. I now the file name (assigned to variable) of a file saved in a folder "user_images" I want to get the image size and assign the values to variables. Link to comment https://forums.phpfreaks.com/topic/60682-get-photo-from-folder-then-get-its-size/ Share on other sites More sharing options...
trq Posted July 19, 2007 Share Posted July 19, 2007 The manual comes in handy....getimagesize(). Link to comment https://forums.phpfreaks.com/topic/60682-get-photo-from-folder-then-get-its-size/#findComment-301881 Share on other sites More sharing options...
cooldude832 Posted July 19, 2007 Share Posted July 19, 2007 I use this, but don't use if you don't understand (its about the learning) <?php $image = ""; $tempimg = getImageSize($image); $size = $tempimg[3]; $size = explode("\"",$size); $width = $size[1]; $height = $size[3]; ?> Link to comment https://forums.phpfreaks.com/topic/60682-get-photo-from-folder-then-get-its-size/#findComment-301883 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.