Welcome Guest, Not a member yet? Register   Sign In
Case in URI's

Hey all,

I'm trying to figure out a way to make www.zzzzz.com/XXX be the same as www.zzzzz.com/xxx. Is this a mod rewrite rule or can it be done in CI?


[eluser]Colin Williams[/eluser]
If you do it at the CI level, say with routes, realize that it will only take effect when CI is handling the request. If you do it at the apache level with mod_rewrite, it would take effect for everything apache is handling (although I don't think you could really do it with pure apache config because you would need something to operate on the string to make it lowercase).

To do it in CI, you might have your best luck by creating a MY_Router.php library that overloads the appropriate methods of CI_Router and converts requests to lowercase [strtolower()] before validating them.


Thanks for the help, but I am still a bit confused.

Why would $route['XXXX']= "xxxx"; not work?

Theme © iAndrew 2016 - Forum software by © MyBB