What are the different types of hook in Codeigniter?

What are the different types of hook in Codeigniter?

Team Leader Asked on February 12, 2017 in CODEIGNITER.
Add Comment
2 Answer(s)

CodeIgniter Hooks allows you to execute a script with specific path within the CodeIgniter execution process without updating or modifying the core files.
If you need to execute a code that should run every time after Constructor of a controller is loaded, you specify that script path in hooks.

Hooks is a PHP file located in following path


The different types of hooks are:

{i} post_controller_constructor
{ii} pre_controller
{iii} pre_system
{iv} post_system
{v} cache_override
{vi} display_override
{vii} post_controller

Senior Developer Answered on February 12, 2017.
Add Comment

There are three hooks :

    • Post System




Overrides Hooks



Senior Developer Answered on July 2, 2018.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.