As a PHP developer since the introduction of PHP3, I always insisted on creating my scripts from scratch. I believed that starting from an empty text file was the best, fastest and most lightweight solution. This was what I have been doing for the past years until I read up more about PHP frameworks.
I was extremely skeptic about frameworks, I told myself that PHP is way too advanced already and a framework is simply overkill, that if I needed anything, I would code it myself and take care of it. I ran into CodeIgniter and I was very impressed by their “Blog in 20 minutes” video (which in all honesty can be done in 5 or 10 minutes if the video maker did not go into details). Also, it is open source and accessible to everyone.
We have recently introduced a new dedicated server configuration utility when making orders for our clients (check it out, follow this link and click on “configure server” for any other listed servers: xeon dedicated servers). We had to take care of this and obviously have it up as soon as possible. I had reviewed and checked CodeIgniter so I decided to give it a shot for this project.
Deliver faster results
The results were incredible, the entire utility was done in less than 2 days which seems incredible for the amount of code that would have been required if I did not have a framework, there are numerous places where a lot of time was saved because of CodeIgniter.
Built in form verification was a great time saver; CodeIgniter makes it extremely easy to take care of validating web forms by using a library, verifying the input of the user is as simple as writing the following:
More about this is explained on CodeIgniter’s documentation regarding Form Validation. There are tons of different ways and libraries/classes that permit you to get more done in much less time.
Easily create modular PHP code
CodeIgniter is based on the common concept of “MVC” code, MVC stands for model-view-controller, the three aspects or modules of the application or script that you’re developing. Each aspect focuses on taking care of something specific, the views is basically what the client sees (you could possible call it template), but it’s basically what the client sees, the “controller” is the back-end where everything is executed and everything is programmed there, the models are basically common functions or classes that you’re using
While I tried my best explaining it, the best way to understand MVC coding is by actually giving it a shot and also referring to CodeIgniter documentation regarding the model-view-controller software approach.
The amount of time saved has made us switch over from our own code to running everything through the framework; it simply makes everything so much organized and makes modifications a swift. The amount of time saved plus the impressive software approach leaves your program to be extremely modular and easily expanded.