Code Igniter: Installation and First Run

Code Igniter is an PHP Application Development Framework – a toolkit for PHP developers. The main goal of Code Igniter is to enable developers to develop projects much faster than they could have done ( if they have started from scratch) by providing a rich set of libraries for commonly needed tasks, as well as a simple interface and logical structure to access these libraries.

You can download Code Igniter from http://www.codeigniter.com/

How to Install:

1. Download the zip file from the above URL.

2. unzip the files and put them to your webserver where you want to. lets assume that you put it at codeigniter folder of your web server.

3. Open the application/config/config.php file with a text editor and set your base URL. lets asumme that your base URL is set like this:

$config[‘base_url’] = “http://localhost/codeigniter/”;

4. if you intend to use a database, open the application/config/database.php file with a text editor and set your database settings. Set the following variables according to your setup.

$db[‘default’][‘hostname’] = “localhost”;
$db[‘default’][‘username’] = “admin”;
$db[‘default’][‘password’] = “*****”;
$db[‘default’][‘database’] = “projectone”;
$db[‘default’][‘dbdriver’] = “mysql”;
$db[‘default’][‘dbprefix’] = “”;
$db[‘default’][‘active_r’] = TRUE;
$db[‘default’][‘pconnect’] = TRUE;
$db[‘default’][‘db_debug’] = TRUE;
$db[‘default’][‘cache_on’] = FALSE;
$db[‘default’][‘cachedir’] = “”;

5. now you are ready to run our installed piece of software. in order to run Code Igniter you have to visit the following URL in you web server.

http://localhost/codeigniter/index.php/

if your setup is correct then you will see a welcome page with heading

“Welcome to Code Igniter!”

Now you are ready to work with Code Igniter.

Note: if you try to access the Code Igniter installation like the following then you will definitely get an error message.

http://localhost/codeigniter/

http://localhost/codeigniter/index.php

By default Code Igniter follows (Search Engine Friendly (SEF) URL and for this they use segment based URL which will come to next tutorial.

Advertisements

30 thoughts on “Code Igniter: Installation and First Run

  1. Hisham777 says:

    i recently installed CodeIgniter and i love it.

    am still finding it difficult to find good tutorials about it specially DB related Except of course for the Video on the CodeIgniter site.

    I hope there will be many tutorials to come from your site

    Regards

    Hisham

  2. Pingback: Dr-Hamza’s Space
  3. Pingback: Dr-Hamza’s Space
  4. TRIVUz says:

    Very simple and good instruction… You can write step by step guide to make a blog with code igniter. Lot’s of people looking for that i guess… (once apn a tym meh too lol)…

    good job anyway…

  5. Sparky says:

    Thanks so much! This is just that little bit better than the install guide on the site- I thought I’d done something wrong in a major way, but really I’d just left of the forward slash on the URL lol. Thanks, this helped a lot 😀

    Sparky

  6. Ketan Thaker says:

    Hi,

    I am PHP web developer and wanna use code igniter in my upcoming projects…

    I am have download code igniter 6+ from codeigniter.com but unable to unzip the file….its saying unrecognised compression….

    Please help…

    Thanks in advance!!!

    Ketan Thaker.

  7. Sheridon says:

    Hi Ketan,

    Just found Mizanur’s blog while re-installing CI (Code Igniter). Have you tried downloading it a second or third time?

    It happens sometims that the files get corrupted during download – at least it did for me.

    Good luck,
    Sheridon

    P.S. Awesome blog and good work Mizanur.

  8. sailesh.g says:

    Hi,

    I am PHP web developer and wanna use code igniter in my upcoming projects…

    I have downloaded code igniter from codeigniter.com but unable to configure and make useof it

    Please help…

    Thanks in advance!!!

    sailesh.g

  9. Gmcosta says:

    I’m new with frameworks, and searched but didnt found any info that makes me good enough to run this app.

    can you give me a little help ?

    I see the sucesseful message you said in the post, but I don’t know how to go ahead this page.

    Thanks for now.
    🙂

  10. Bipin kumar says:

    hello everyone,

    I am new in odeignite frame work. when i insatll it in my loacal server. it not run only well come page is displaying.whenever I changed base url in config.php file
    i.e
    $config[‘base_url’] = “http://localhost/CodeIgniter/”;

    but it not work.
    please help me

  11. Aruna says:

    hi ,
    each time when i invoke a function in the model,the previously incremented value is not coming???Resolve the problem……….

  12. Janine says:

    hey could u please please help me…ok i’m like totally new to the field altogether but i need to develop an application and its an emergency. you really need to address me in a “codeigniter for dummies” kinda way. what is my web server. where do i find a folder like that and how do i put the code igniter unzipped folder into it… as in where? i obviously havent done the set up right because im, not geting the welcome page

  13. suherman says:

    I’ve installed codeigniter but show message error:

    “Fatal error: Call to undefined function: ob_get_level() in c:\apache\htdocs\codeigniter\system\libraries\Exceptions.php on line 57”

    should show

    “Welcome to Code Igniter!”

    Please help, thanks.

  14. pawan guleria says:

    hello everyone,

    I am new in odeignite frame work. when i insatll it in my loacal server. it not run only well come page is displaying.whenever I changed base url in config.php file
    i.e
    $config[‘base_url’] = “http://localhost/CodeIgniter/”;

    but it not work.
    please help me

  15. Karl Tingume says:

    i am new in codeigniter and even while installing and running my first program (Helloworld), my controller cannot be recognized and i don’t know why. somebody help me and really soon!!!!!!!!!!

  16. madhu nandu says:

    j have saw the sample codings in net and apply in my codeigniter framework but i dont know how to run that and saw the output please help me.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s