GetDotted Domains

Viewing Thread:
"PHP and Images."

The "Freeola Customer Forum" forum, which includes Retro Game Reviews, has been archived and is now read-only. You cannot post here or create a new thread or review on this forum.

Mon 21/04/03 at 14:08
Regular
Posts: 787
Is there any built-in functions which allow PHP to determin the Width and Height of an Image???
Mon 21/04/03 at 22:19
Regular
"It goes so quickly"
Posts: 4,083
$Size[3] ... I know :)
Mon 21/04/03 at 22:04
Regular
"Eff, you see, kay?"
Posts: 14,156
One of the functions actually creates the string for you to put inside the tag you know. I can get it when I get home.
Mon 21/04/03 at 14:23
Regular
"It goes so quickly"
Posts: 4,083
It's ok, knew it was in the PHP Manual somewhere :)

For anyone who wants to know, its "getimagesize();" and requires the Image Name you want to get the details from.



You are given 4 array elements within the returned $Size.

$Size[0] is the Width of the Image in pixals (e.g. '50').
$Size[1] is the Height of the Image in pixals (e.g. '40').
$Size[2] is the Flag of the Image type (e.g. '1 = gif, 2 = jpg' etc).
$Size[3] is the basic HTML Code for an tag (e.g. 'width="50" height="40"').
So you can have: />
in place of:
Mon 21/04/03 at 14:08
Regular
"It goes so quickly"
Posts: 4,083
Is there any built-in functions which allow PHP to determin the Width and Height of an Image???

Freeola & GetDotted are rated 5 Stars

Check out some of our customer reviews below:

First Class!
I feel that your service on this occasion was absolutely first class - a model of excellence. After this, I hope to stay with Freeola for a long time!
I've been with Freeola for 14 years...
I've been with Freeola for 14 years now, and in that time you have proven time and time again to be a top-ranking internet service provider and unbeatable hosting service. Thank you.
Anthony

View More Reviews

Need some help? Give us a call on 01376 55 60 60

Go to Support Centre

It appears you are using an old browser, as such, some parts of the Freeola and Getdotted site will not work as intended. Using the latest version of your browser, or another browser such as Google Chrome, Mozilla Firefox, or Opera will provide a better, safer browsing experience for you.