Loading ...
Sorry, an error occurred while loading the content.

Re: [phpexperts] Re: Image Resizing

Expand Messages
  • Mahbubul Islam
    Thanks Hasin Vai... It s really handy and easy to understand.And I would like to thanks all members of this group.. Sohag Day Dreamer
    Message 1 of 2 , Nov 1, 2004
    • 0 Attachment
      Thanks Hasin Vai...
       
      It's really handy and easy to understand.And I would like to thanks all members of this group..
       
      Sohag

      Day Dreamer <augustwind16@...> wrote:


      Hello Mr. Oshim,
      I think mahbub is right and it needs ImageMagic library to be
      installed. A better solution could be this.

      # I assume the orriginal image is of JPEG format

      <?
      $desired_height = 300;
      $desired_width = 400;
      $im_dst = imagecreate($desired_width, $desired_height);
      $im_org =  imagecreatefromjpeg($filename);
      list($width, $height, $type, $attr) = getimagesize($filename);
      imagecopy($img_dst,$img_org,$desired_width,$desired_height,0,0,$width,$height);
      header("Content-type: image/jpg");
      imagejpeg($img_dst);
      ?>

      Thanks

      --August








      Visit Dynamic URL Shortening System : http://www.magicurl.info



      Do you Yahoo!?
      Take Yahoo! Mail with you! Get it on your mobile phone.

    Your message has been successfully submitted and would be delivered to recipients shortly.