Get image details from a jpeg file

Discussion in 'Programming' started by shredder81, Apr 20, 2010.

  1. #1
    Anyone know for a script or how I would go about getting the details from a image file and getting them to display on the screen. If you where to right click on a jpeg file in windows and choose properties then details. There is some info in there how would I display that on the screen.
     
    shredder81, Apr 20, 2010 IP
  2. 911voodoo911

    911voodoo911 Member

    Messages:
    52
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    38
    #2
    If i get it right, yo have to use grafic commands of PHP, you can get dimension, pattern and others.
     
    911voodoo911, Apr 20, 2010 IP
  3. crivion

    crivion Notable Member

    Messages:
    1,669
    Likes Received:
    45
    Best Answers:
    0
    Trophy Points:
    210
    Digital Goods:
    3
    #3
    <?php
    $img = "images/empty.gif";

    list($width, $height, $type, $attr) = getimagesize($img);

    print "Width : $width and height = $height";
    ?>
     
    crivion, Apr 21, 2010 IP