Introduction to CodeIgniter and Installation

0
92
Reading a CSV file in PHP
Introduction to Prestashop, an open source E-Commerce system

Codeigniter logoThis post is an Introduction to Codeigniter and Installation of CodeIgniter (CI), which  is a power full and FREE open source PHP MVC framework. Its size is very small and is about 1.2 MB and it has almost all features you will need for a full fledged framework. Its main aim is to provide a set of tools which enable developers to build the web applications very fast and easily.

CodeIgniter has all sort of libraries which a developer need for a web application development including database drivers, cache system, Language, Sessions, Emailing, Benchmarking, Encryption, Pagination, Security, Form validations and so on. If some features are not available in CodeIgniter, then you can find easily third party libraries for them.

Beside libraries, CodeIgniter also provides Helpers. As the name shows, these are small code snippets (Not really small 😉 ) which you can use whenever you need. Helpers are normal PHP functions and provide very useful features. CodeIgniter includes a very nice set of Helpers which includes Array helper, CAPTCHA , Email, File, Language, Path Helper, URL, Strings and so on.

CodeIgniter has a very nice documentation with examples if needed. The documentation or user guide provides all details about the framework and to learn CodeIgniter, you just need that documentation. That documentation provides full details about the framework structure, working, all libraries details, helpers details, and how to work in CodeIgniter. This documentation covered all aspects of the CodeIgniter including how to create your own libraries and helpers. In short you will find every information about CodeIgniter in the documentation you will need.

You can download CodeIgniter from Codeigniter site . The download has the core CodeIgniter system and the user guide or documentation. After you download the CodeIgniter, unzip the file, and you will have the core system and the user guide.  In the folder where you have extracted the downloaded file, you will have a set of folders and files. Folders are application, system and user_guide and files are index.php and license.txt . Move the user_guide folder to another place for your reference as you will need it. The application folder will be having your web application. It will have controllers, views files, your own libraries or third party libraries, your own or third party helpers and your models etc etc. The core CodeIgniter system is placed in the system folder.

Installing CodeIgniter is very easy and requires very less configuration and it does not need to use command line. Make a folder named codeigniter at your server, and copy folders application, system and files index.php , and that’s it, the installation is completed. Now you will need to make a little configuration. Open application/config/config.php file and set the base_url to your desired url. If your site link is http://localhost/programmingtunes.com , then the base_url will be ” http://localhost/programmingtunes.com/codeigniter/ ” . Some other configurations can be also made in config.php which you will learn later on.  If you are using database then you can make database configuration in config/database.php . Now your installation is completed. To test the installation, type the url in browser and hit enter. If you see the following welcome screen, then your installation is successfully completed and you are ready to start work in CodeIgniter.

CI installation welcome screen
After CI installation is successful you will see this welcome screen when you type the url in browser

Finally, if you want a fast, secure and easy to use, easy to modify PHP Framework, then Codeigniter is for you. This was a post for Introduction to Codeigniter and installation, read my next post for a Hello World program.

Reading a CSV file in PHP
Introduction to Prestashop, an open source E-Commerce system

Leave a Reply