Welcome Guest, Not a member yet? Register   Sign In
Sub-folder controllers question
#1

[eluser]@li[/eluser]
Lets say in my application/controllers folder, I have these folders:

application/controllers/admin/
application/controllers/general/
application/controllers/members/

If in my admin area, I want to create another folder, such as:
application/controllers/admin/affiliates/

and have it store my controllers, e.g:
application/controllers/admin/affiliates/search.php
application/controllers/admin/affiliates/reports.php
(and so on)

Is it possible? Right now, if I attempt that and go to:
http://localhost/directory/project/admin/affiliates/

then instead of loading the default controller (welcome.php)in the affiliates directory, it gives a 404 error.

Any ideas?
#2

[eluser]@li[/eluser]
Bump. Anyone? I just want to know if its possible to have more sub-directories in a controller subdirectory, e.g:

application/controllers/dir1/dir2/controller.php

Is this possible?
#3

[eluser]thurting[/eluser]
yes. you will have to set up the routing though. check the manual for help with routing.
#4

[eluser]Phil Sturgeon[/eluser]
This took me so long to find the solution, if only there was some tool on this site that allowedf me to put in obvious keywords so it returned results based on what it is im looking for... oh wait... it does!! :p

Controllers in Unlimited Nested Folders




Theme © iAndrew 2016 - Forum software by © MyBB