crop image using jquery and CodeIgniter

Crop image using jquery and codeigniter framework.

Today I will explain how to crop the image using jquery and CodeIgniter framework.
For this, I used imageareaselect.js jquery plugin and imgareaselect-default.css files.If you are creating crop image functionality for profile pic updates and your application is getting high traffic , you need to take good Virtual Private Servers, Built for Open Source Developers, Fully managed, lightning-fast, starting at $15/mo with 1GB RAM!, a developer running a complex application that requires instant scalability, or a designer wanting to give your clients’ sites maximum performance, then VPS hosting is just what you need!

Now I will create a view to upload the image using frontend request,for this I created a view file named cropimage.php

When user send the file upload request to controller function crop image()
This request will call model function to upload a file using codeigniter default library upload.

READ  Jquery popup slider using codeigniter.

Now create controller name as welcome.php


Now we will look up model functions to upload image file to uploads folder and saving file name to database.

READ  Jquery popup in for loop using codeigniter

Now create model name as ektreemodel.php

In the above code, I used a upload thumbnail () function to create crop image into uploads folder and save it to the database.
Here to create thumbnail I had taken selected image x-axis, y-axis, height and width of the selected image areas dimensions.

READ  Codeigniter advanced search functionality implementation.

Thanks for reading this article.

To Download Crop Image Functionality Please add blow details

[sdm_download id=”73″ fancy=”0″][sdm_download_counter id=”73″]


  1. Ashish March 8, 2018
  2. crop photo April 17, 2018
  3. sangeetha March 20, 2019

Leave a Reply