# \[PHP\] Image size and dimensions

**URL:** https://forum.kirupa.com/t/php-image-size-and-dimensions/212663
**Category:** programming
**Created:** [January 12, 2007, 9:58pm UTC](https://forum.kirupa.com/t/php-image-size-and-dimensions/212663 "2007-01-12T21:58:43Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![NeoDreamer](https://avatars.discourse-cdn.com/v4/letter/n/ccd318/32.png) [@NeoDreamer](https://forum.kirupa.com/u/NeoDreamer)
#### Post date: [January 12, 2007, 9:58pm UTC](https://forum.kirupa.com/t/php-image-size-and-dimensions/212663/1 "2007-01-12T21:58:43Z")

</div>

I made a form that sends an email with an image attachement. Now, how do I check the file size in kilobytes, dimensions (width and height) in pixels, and file type (gif or jpg)?

Is it something like:

$att\_size = $\_FILES[‘att’][‘size’];
