The framework can be interpreted simply as a library containing a collection of functions / procedures and classes for specific purposes that are ready to be used so that it can facilitate and accelerate the work of a programmer, without having to create a function or class from the start.
Advantages of using the framework are:
- provide a good structure in our program. Sometimes as programmers, we can create our program structure. the framework, we can make the program more structured, easy to manage, easy to develop.
- well for those that have been used to make the program itself, usually on their own to create a framework in the program can easily develop, that could be a problem is the use of this framework is the subjective easily according to our perspective. with a framework that is used by many people, it will provide the structure and way of working standards for our applications. The more people who use it, it means a lot of people who agree with the way the framework works. people learning framework means we have to adjust the way in which people work is possible in accordance with our style gag. But from another perspective, by studying the framework, we can add insight that could improve our performance.
- the framework, the development could be faster. In web applications, certainly a lot of the same work done on every application that we created (eg, generate page, database access, display tables, searching, paging, URL management, login, password reset, access control, etc.).
- increase security. General framework created by people who are experienced in their field. With experience, plus contributions from users of the framework, will improve the quality and safety applications.
Why use CodeIgniter:
CodeIgniter is an Application Development Framework is a toolkit that is suitable for novice programmers to build a website using PHP. Its main purpose is to allow you to develop projects much faster than if you write the code from scratch. CodeIgniter is a framework that I think provides a complete set of functions that are relatively able to make you more focused on the project by minimizing the amount of code needed for a specific task.CodeIgniter (CI) also has a number of advantages compared to other PHP Framework. such as:
1. Performance is very fast.
One reason for not using the framework is that the execution is slower than PHP from the scratch. CodeIgniter is very fast but may even be considered a framework that is much faster than other frameworks.
2. Configure the very minimum (nearly zero configuration).Usually we need to adjust the database and the routing path by changing some configuration files like database.php or autoload.php. But to use CodeIgniter with standard settings, you just need to change a few files in the config folder.
3. Support community.
CI has long circulated in the programmer. Even in its heyday around 2011. Although it is now emerging frameworks of other stars, because the world is always spinning quickly programmer, CI has relatively strong user community support. Forum Ellislab example, so that we can more easily interact with those who know better.
4. Documentation is complete.
Each installation package CodeIgniter user guide is accompanied by a very nice and well equipped to make a beginning, language was easy to understand.
5. Using the MVC pattern.
By using the MVC (Model-View-Controller), the code becomes more structured and have clear standards.
Why use Yii
1. Yii is a framework that uses PDO.PDO works by creating a database access abstraction that we as programmers do not have too much to think about compatibility between databases. nah with abstractions, we can more easily if you want to switch databases. The original structure is the same, we can move smoothly. if we consider the application made by the mysql centric like wordpress, and client Controller sql server?
2. Yii is a full OOP framework.
where to OOP, we better manage the code, we can classified function into classes, to modify the program better, the program can be neater and easier to read. well this is where I think the biggest challenge Yii, because from what I saw most of the programmers who have yet to master OOP applied properly (when the department of informatics tablets).
3. Yii model using MVC (model view controller).
MVC we can be structured in making our application. we do not need to make a lot of files in the root directory of our application (eg. login.php, index.php, cekstatus.php, displayuser.php, etc.).
4. Yii has a BSD license.
BSD license, not the GPL. from what I know, the BSD license does not require us to delivers source code of our application.
5. Yii has a code generator (gii).
I think this is one tool that helps speed the development of our application. gii tool is able to generate code and then modified by us. we just enter the name of the table, make a few clicks, and gii will instantly create a model, view, and controller for us. Interesting is not it? It's still, in modifying the model, view, controller, it must know OOP.
6. Yii has a component for checking input.
I think this is a good and useful feature for security. if we create a webform, usually we do not own functions to sanitize input, right? ie we have to check that the input character, or numbers, or have a date format. but in yii, a check is already integrated and automated with gii.