CodeIgniter Forums

Full Version: Is it possible in codeigniter 3x.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello Brothers,
I'm working with codeigniter since 2.5 year And I love this framework.
But now i need/want to add sub-directories in controller or model folder.
I tried this but getting 404 error.

PHP Code:
controller/Admin/Admin.php 
PHP Code:
models Admin model_admin.php 

Many Thanks. Smile
Keep the dir name in lowcase, and Class file in Ucfirst,and try again
The docs show how to load models in subdirectories here:
https://www.codeigniter.com/user_guide/l...oader.html

PHP Code:
$this->load->model('admin/model_admin'); 

As for the controllers in subdirectories, see here:
https://www.codeigniter.com/user_guide/g...irectories
(12-26-2015, 12:16 AM)skunkbad Wrote: [ -> ]The docs show how to load models in subdirectories here:
https://www.codeigniter.com/user_guide/l...oader.html

PHP Code:
$this->load->model('admin/model_admin'); 

As for the controllers in subdirectories, see here:
https://www.codeigniter.com/user_guide/g...irectories

Thank you.