Welcome Guest, Not a member yet? Register   Sign In
Default Controller
#5

[eluser]kenjis[/eluser]
[quote author="gazza" date="1212974440"]I don't know why you would assume the default controller in the directory should be welcome everytime. Currently it will look for hoge controller and then index function. If that isn't found then the sub directory but without another parameter in the url it wont know what controller in that directory. I cannot explain however the absence of the 404 error.
[/quote]

You're right, and I expect CI to assume the default controller in a sub directory is 'subdir/welcome' (of course you can change 'welcome' in routes.conf).

Because I want to use shortest URI.

In the current spec, most shortest URL using sub directory is like:
Code:
http://example.com/subdir/welcome

If default controller is the controller in sub directory, I can remove
welcome and URL will be like:
Code:
http://example.com/subdir/

And the current spec is not intuitive. If URL is including sub directory, most people expect controllers in sub directory, doesn't they? But CI returns the controller in top directory.


Messages In This Thread
Default Controller - by El Forum - 06-08-2008, 02:26 AM
Default Controller - by El Forum - 06-08-2008, 02:45 AM
Default Controller - by El Forum - 06-08-2008, 02:20 PM
Default Controller - by El Forum - 06-08-2008, 03:47 PM
Default Controller - by El Forum - 06-08-2008, 04:15 PM
Default Controller - by El Forum - 06-08-2008, 10:43 PM
Default Controller - by El Forum - 06-10-2008, 08:17 AM
Default Controller - by El Forum - 07-07-2008, 07:24 PM
Default Controller - by El Forum - 07-11-2008, 02:44 AM



Theme © iAndrew 2016 - Forum software by © MyBB