Image upload can be a pain in the *ss. And even though CI has a lot to offer (in the means of documentation) it still lacks a direct copy-paste code on their website so that people can just put it into their controller and use away. Here we will have:

  • Image upload form with 5 images
  • And a controller function that will upload those
  • Thumbnails will be there too 😉

Ok, lets start with the HTML form code, it is very basic:

And now the controller:

And that is it. Customize it to your needs, the basics are there already. And good luck!