I recommend the Zebra PHP Component imageTransformation class. It works very well and is very easy to implement. On Thu, Sep 3, 2009 at 8:55 AM, Hari KT <kthari85@xxxxxxxxxxx> wrote: > > > Hi man, > > There are lots of codes in php.net itself . If you need something you may > need to browse through it . > > This is a sample I have got from there . I have not tried it . But this is > how it works . You can look the functions and get more details .. > > <?php > // File and new size > $filename = 'test.jpg'; > $percent = 0.5; > > // Content type > header('Content-type: image/jpeg'); > > // Get new sizes > list($width, $height) = getimagesize($filename); > $newwidth = $width * $percent; > $newheight = $height * $percent; > > // Load > $thumb = imagecreatetruecolor($newwidth, $newheight); > $source = imagecreatefromjpeg($filename); > > // Resize > > imagecopyresized($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); > > // Output > imagejpeg($thumb); > ?> > > http://us2.php.net/manual/en/function.imagecopyresized.php > > Hari K T > > http://harikt.com/ > > --- On Tue, 1/9/09, hno <hno2005@xxxxxxxxx <hno2005%40gmail.com>> wrote: > > From: hno <hno2005@xxxxxxxxx <hno2005%40gmail.com>> > Subject: How to reduce the image size > To: php-objects@xxxxxxxxxxxxxxx <php-objects%40yahoogroups.com> > Date: Tuesday, 1 September, 2009, 10:42 PM > > > > HI > > How can reduce the image size in php ? > > Best Regards > > HNO > > [Non-text portions of this message have been removed] > > > > > > > > > > > > Beauty is just a click away. Find beauty parlor listings on Yahoo! India > Local http://in.local.yahoo.com/ > > [Non-text portions of this message have been removed] > > > [Non-text portions of this message have been removed]