• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Multiple Applications & Routing Problem (Bug?)

[eluser]omed habib[/eluser]
I'm running multiple websites with one installation of codeigniter. Each application has its own custom named 'application' folder and is being set in the index.php (as it should).

One of the applications has a folder in the controllers directory with controllers within it. The default for that controller is being set in the routes.php file, like this:

$route['manage'] = "manage/login";

The problem is, when I try to access mysite.com/manage, I get nothing. Furthermore, when I try to skip the routing and try to access mysite.com/manage/index, I still get nothing.

I'm forced to believe that multiple applications within a framework leads to the inability to setup directories to organize controllers. Does anyone have any experience/thoughts on this?


Is "manage" a controller or a directory?, if it's a contoller there must not be a directory of the same name.
If it's a directory, you cannot have a Controller named Index. Can you explain the structure a bit more clearly.

[eluser]omed habib[/eluser]
Whoops... typo.

/manage/ is a folder, so my controllers directory looks like this:


Ok, try:
$route['manage'] = "manage/login/index";

[eluser]omed habib[/eluser]
wiredesignz, no luck. Still gives me the same 404 error.

[eluser]Billy Khan[/eluser]
Did you manage a fix for this? I am having exactly the same problem. I moved my apps into applicaion sub dir and now the routing has stopped.


Originally it was /admin which got me to my admin system
I have now moved it into application/admin and created an admin.php in the web root and modified the application var to application/admin.

I would like to do this:
/admin but i have to instead go to /admin/admin. No matter what i do with the routing in cant get it to find the controllers with just /admin.

My controllers are in sub dir as well, e.g. application/admin/controllers/login/c_login.php with my route set to:

"admin" = "login/c_login"

[eluser]Billy Khan[/eluser]
I can confirm that when relocating the application folder, controllers in sub directories arent found. I tried it with a default CI installation. I relocated the application folder and moved welcome into hello/welcome and altered the route.

Is there a solution to this?

[eluser]Billy Khan[/eluser]
Can anyone else confirm that this is that case? That when relocating the application folder, controllers in sub-directories arent loaded.

Reason is that i have developed my own CMS and have controllers all organised into subfolders and dont want to move them to the root of "controllers"

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.