Getting Started With CodeIgniter : PHP Framework

Getting Started With CodeIgniter : PHP Framework
January 27, 2017 No Comments Uncategorized Minal Landge

 

CodeIgniter : PHP Framework

 

codeIgniter

codeigniter

Introduction

CodeIgniter is an Application Framework:

CodeIgniter is a  PHP framework or a toolkit for people who build web applications using PHP . It has a very rich set of libraries and helpers which makes coding in PHP simple, quick and user-friendly. As well as it provide simple interface and logical structure to access these libraries. This Framework minimizing the amount of code needed for a given task.

CodeIgniter is Free:

It is a powerful open-source PHP framework created by Rick Ellis in 2006. This framework is licensed under the MIT license so you can use it however you please.

CodeIgniter is Light Weight:

CodeIgniter  is very popular framework having  very small footprint. The core system requires only a few very small libraries.

CodeIgniter Generates Clean URLs:

The URLs generated by CodeIgniter are clean and search-engine (SEO) friendly. You can construct your own URI lines in CodeIgniter.

CodeIgniter is Secure:

A website built in Codeigniter is secure.As it has the ability to prevent various attacks that take place through websites. CodeIgniter comes with XSS filtering security. Secure your site from CSRF(Cross Site Request Forgery).

CodeIgniter Uses M-V-C:

It is  loosely based on the popular Model-View-Controller(MVC) development pattern, which allows great separation between logic and presentation.

MVC-Architecture

MVC-Architecture

Controller:
  •  A controller is a simple class file which translates user input into operations on the model.
  • The Controller serves as an intermediary between the Model, the View ,and any other resources needed to run your application.
  • Path of controller file=>
  •       Your Application name->application -> Controller-> Test.php
Model:
  1. The Model represents your data structures.
  2. Models are PHP classes that are designed to work with information in your database.
  3. Model will contain functions that help you retrieve, insert and update information in your database.
  4. Path of model file=>

    Your Application name->application -> Model->Test_model.php

View:
  1. View is the simple web page. This webpage may contain header, footer, sidebar etc.
  2. View cannot be called directly.
  3. Path of controller file=>

   Your Application name->application -> view->test.php

 

CodeIgniter is Extensible:

The system can be easily extended through the use of your own libraries, helpers, or through system hooks.


CodeIgniter Features

1. Loosely based on Model-View-Controller pattern

2. Extremely Light Weight

3. Form and Data Validation

4. Security

5. Session Management

6. Email Sending Class. Supports Attachments, HTML/Text email, multiple protocols (sendmail, SMTP, and Mail) and more.

7. Image Manipulation Library (cropping, resizing, rotating, etc.).

8. File Uploading Class

9. Pagination

10. Data Encryption

11. Error Logging

12. Zip Encoding Class

13. Search-engine Friendly URLs

14. Flexible URI Routing

15. Full Featured database classes with support for several platforms

16.Query Builder Database Support

17. Support for Hooks and Class Extensions

18. Large library of “helper” functions


  • Application Flow Chart

The following structure illustrates data flow throughout the system:

Flow Chart

Flow Chart

1.The index.php serves as the front controller, initializing the base resources needed to run CodeIgniter.

2.The Router examines the HTTP request to determine what should be done with it.

3.If a cache file exists, it is sent directly to the browser, bypassing the normal system execution.

4.Before the application controller is loaded, the HTTP request and any user submitted data is filtered for security.

5.The Application Controller loads the model, core libraries, plugins, helpers, and any other resource needed to process the specific request.

  • 6.The finalized View is rendered then sent to the web browser to be seen. If caching is enabled, the view is cached first so that on subsequent requests it can be served.

 

  • Design and Architectural Goals

  •  1. Maximum Performance
  •  2. Capability
  •  3. Security
  •  4. Flexibility
  •  5. Lightest possible package.
  •  6. Very Loosely Coupled system.
  •  7. CodeIgniter is a dynamically instantiated with high component singularity. It strives for simplicity, flexibility, and high performance in a small footprint package.

 

Tags
About The Author

Leave a reply

Your email address will not be published. Required fields are marked *