codeigniter - overwrrite code igniter Common.php -


there method in code igniter under system/core/common.php called load_class().

i overwrite method. overwrite code igniter class create file such my_common.php in case common.php collection of methods , there no classes encapsulates them.

so how do this?

there's no officially supported way built in extending mechanisms. consider other way achieve goal.

however functions inside common.php wrapped inside if checking if function exists or not can following:

  1. create my_common.php put somewhere in project (maybe application/core/ mirror other similar extends)
  2. open index.php file in root of project
  3. insert include apppath.'core/my_common.php'; before closing
    require_once basepath.'core/codeigniter.php'; line

now if have have load_class function in my_common.php shadow original version.


Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -