Cropic Image Cropping Pluggin for Codeigniter

Download Source file

DEMO/ OUTPUT

( display url after cropping )

To Store the image in mydql Database, Folow the below code

Step1: Create databse

CREATE TABLE IF NOT EXISTS `logo` ( `id` int(11) NOT NULL, `photo` varchar(255) COLLATE utf8_unicode_ci NOT NULL ) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

Step2: In controller home.php
imagejpeg($final_image, $output_filename.$type, $jpeg_quality);
$response = Array(
"status" => 'success',
"url" => base_url(). $output_filename.$type );
$output=str_replace('temp/', '', $output_filename);
$file=array(
'photo'=>$output,
);
$this->Logo_model->store_logo($file);

Step3: In model Logo_model.php
function store_logo($file)
{
$insert = $this->db->update('logo', $file);
return $insert;
}
Tag Cloud:-Codeigniter Cropic Pluggin, Easy image Cropping PHP Codeiginter