[eluser]alrightythen[/eluser]
Does anyone have a solution for this problem? I'm kind of facing the same issue.
My photo uploads to the server in a folder I created dynamically like this
Code:
mkdir($dir, 0700, true);
The uploading works, the creating the thumb works.
But now I want to resize the original photo so that it could fit in a fixed box. But it doesn't work.
This is the code in wich i want to resize my original photo.
Code:
$config['image_library'] = 'gd2';
$config['source_image'] = $dir.$file;
$config['maintain_ratio'] = TRUE;
$config['height'] = 475;
$config['width'] = 680;
$this->load->library('image_lib', $config);
$this->image_lib->clear();
$this->image_lib->initialize($config);
if(!$this->image_lib->resize()) echo $this->image_lib->display_errors('<p>', '</p>');
I've placed echo statements on eachline to test. and I runs every line except the last line. I don't know what i'm doing wrong, I've just copypasted the code from my thumbCreate()