Codeigniter Controller

Codeigniter Controller is simply class name which contains methods inside it.

All the controllers are kept inside the application/controllers folder.

Codeigniter Controller Syntax

Lets start with a simple controller named as “Helloworld”.

Try it ยป

Note Class name must start with uppercase

Not Like This :

Now visit your site as :


If you have not removed the index.php from url

Note : Default function index() will be called

Which is :