FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Getting height and width from an image





Roald
I have some images that are uploaded, is it possible to check there width and height with PHP?
desertwind
you can use getimagesize($filename) method.

It will return an array with 5 elements. Index 0 and 1 contains respectively the width and the height of the image.
Roald
Thanks that was were I was looking for.
infobankr
For what its worth (FWIW), check out gd - it is a php library with many many image options.

As a separate alternative, you could also use javascript to get the width and height.
Roald
I know gd but it's not usefull for what I want to do.
Related topics
The new norm for website height/width?
Tool to create shadow effect for an Image using CSS
How to detect a file is that jpeg image or gif image ?
image php sripting that made a image refreshed every loaded
CSS Problems and Questions.
Tutorials
need advice on making wed site
HTML editing Software
Why this PNG code don;t work ?
Avatars
Thumbnail Generation !
Help with imagecopy
Need Serious help !!!!!! plzzzz
100-150frih$ for simple image
Reply to topic    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.