Codeigniter - SPLessons

CodeIgniter Configuration

Home > Lesson > Chapter 5
SPLessons 5 Steps, 3 Clicks
5 Steps - 3 Clicks

CodeIgniter Configuration

CodeIgniter Configuration

shape Description

After installation of CodeIgniter is done, CodeIgniter Configuration has to setup which involves two types.

shape Step-1

URL configuration

For running CodeIgniter application, setup the correct base URL of the website. To do this, open config.php in xampp/htdocs/codeigniter/application/config folder and edit the base_url array item. This sets the connection between server and the CodeIgniter folder.

shape Step-2

Testing CodeIgniter

Here quick test to be done to see whether CodeIgniter application is running properly or not. Go to http://localhost/codeigniter and should see the following. If observed, Codeigniter is working proper and configuration is success or not.

shape Step-3

To change the default controller name, use
$route['default_controller'] = "Your_own_controller";

shape Step-4

Datbase configuration

Connect local database to server from database.php in xampp/htdocs/CodeIgniter/application/config folder and do the following changes.

shape Step-5

Set the autoload libraries, database and helpers like form, url as per needed in autoload.php within xampp/htdocs/CodeIgniter/application/config/ folder by changing the following variables as below.

Summary

shape Key Points

  • URL Configuration and Database Configuration has to be done for CodeIgniter Configuration.