• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
png image resize

#1
copy($image, $target);
              
                // resize to 'md' size
                $resize_config['source_image'] = $target;
                $resize_config['new_image'] = $target;
                $resize_config['width'] = $dimensions['width'];
                $resize_config['height'] = $dimensions['height'];
                $resize_config['master_dim'] = 'width';
               
                $ci->image_lib->initialize($resize_config);
              
                $ci->image_lib->resize();




It works for jpg images but not png images. For a png image it is doing the copy to the target directory then stopping when it comes to the resize



The original size is Width = 620px Height = 413px


The array for setting the new size is array ('width' => 685, 'height' => 526)





Thanks
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.