Welcome Guest, Not a member yet? Register   Sign In
Image Resizing
#1

[eluser]Philo01[/eluser]
Hi all! Smile

I have a small problem with resizing images.

Code:
$config['source_image'] = $uploaddata['full_path'];
            $config['width'] = 800;
            $config['height'] = 600;
            $this->load->library('image_lib', $config);
            
            if($this->image_lib->resize()){
                log_message('debug', 'Image has been resized to light box dimensions');
            }
            
            $this->image_lib->clear();
            
            $config['source_image'] = $uploaddata['full_path'];
            $config['width'] = 300;
            $config['height'] = 300;
            $config['create_thumb'] = TRUE;
            $config['new_image'] = $upload_dir;
            
            $this->load->library('image_lib', $config);
            
            if($this->image_lib->resize()){
                log_message('debug', 'Image copy has been made and resized');
            }

Now the strange part is, that it does runs the first resize code.
When it goes to the second part that create's a thumb it gives the following error:

"Your server does not support the GD function required to process this type of image"

I am using GD2. I also tried to simply resize the image again (so no thumb etc, just the the first resize code) but it gives the same error.
So basically everything after the first resize returns an error.

Anyone who can help me out with this Smile

Would appreciate it!

Thanks!


Messages In This Thread
Image Resizing - by El Forum - 09-09-2010, 08:24 AM
Image Resizing - by El Forum - 09-09-2010, 08:30 AM
Image Resizing - by El Forum - 09-09-2010, 08:41 AM



Theme © iAndrew 2016 - Forum software by © MyBB