Click here to Skip to main content
15,850,360 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello! There is my function:

<? function resize_image($path, $path_image)
       $CI = & get_instance();

       $config = array();

       $config['image_library'] = 'ImageMagick';
       $config['source_image'] = $path; //full path
       $config['new_image'] = $path_image.'new_image.jpg';
       $config['create_thumb'] = TRUE; // ставим флаг создания эскиза
       $config['maintain_ratio'] = TRUE; // сохранять пропорции
       $config['width']     = 200; // и задаем размеры
       $config['height']   = 200;


           if ( ! $CI->image_lib->resize())
               echo $CI->image_lib->display_errors();


I try to make thumb image by library ImageMagick, but i get error:
The path to your image library is not correct. Please set the correct path in your image preferences.
How fix it?
Richard C Bishop 6-May-13 10:09am    
I would say providing the correct path should do the trick.
Jardin1 6-May-13 15:21pm    
Where i can set it correct path?
Mohibur Rashid 6-May-13 23:51pm    
when you call resize_image function then
Prasad Khandekar 7-May-13 11:20am    
May be there is a better way. Please refer to this manual (

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900