Welcome Guest, Not a member yet? Register   Sign In
How can i remove subclass_prefix?
#1

Hello, i want to remove subclass_prefix thing in my codeigniter project. How can i do that?


[Image: 59979090-b9e29c00-95eb-11e9-8c01-00d47296b0fd.png]

I tried this. This doesnt work. I dont want to use subclass prefix. For now i solve this problem with a trick. I extend my Admin_Controller.php class from MY_Controller. This way is so complex.
Reply
#2

The 'subclass_prefix' is only used when extending a core class and then it MUST be used. There is no getting around it.
Reply
#3

Try this: https://markladoux.wordpress.com/2012/12...-modified/


I've modified it when it stopped working with CI 2, but it should still work with CI 3. It doesn't remove the need to extend CI_Controller at some point, nor does it remove the need for a prefix. It does, however, remove the need to use the prefix specified in your configuration on controllers. Just make sure you extend the alternative base controller.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB